com.kuka.resource.pool
Interface TypedFacadePool<T>

Type Parameters:
T - The facade type.

public interface TypedFacadePool<T>

A generic version of the FacadePool interface. It provides the same functions but removes the class parameter and is preset to a single facade type.


Method Summary
 void addListener(FacadeListener<? super T> listener)
           
 Collection<T> getAll()
          Returns facades for all resources that matches the specified facade class.
 Collection<T> getAll(FacadeFilter<? super T> filter)
          Returns facades for all resources that pass the specified filter and match the specified facade class.
 T getAny()
          Returns a facade for the first resource that matches the specified facade class.
 T getAny(FacadeFilter<? super T> filter)
          Returns a facade for the first resource that passes the specified filter and matches the specified facade class.
 T getFacade(com.kuka.resource.IResource resource)
          Tries to create a facade of the specified type for the specified resource.
 void removeListener(FacadeListener<? super T> listener)
           
 int size()
           
 

Method Detail

size

int size()
Returns:
the current count of all facades of type T in the pool

getAny

T getAny()
Returns a facade for the first resource that matches the specified facade class.

Returns:
A concrete resource facade.

getAny

T getAny(FacadeFilter<? super T> filter)
Returns a facade for the first resource that passes the specified filter and matches the specified facade class.

Parameters:
filter - A facade filter.
Returns:
A concrete resource facade.

getAll

Collection<T> getAll()
Returns facades for all resources that matches the specified facade class.

Returns:
Concrete resource facades.

getAll

Collection<T> getAll(FacadeFilter<? super T> filter)
Returns facades for all resources that pass the specified filter and match the specified facade class.

Parameters:
filter - A facade filter.
Returns:
Concrete resource facades.

getFacade

T getFacade(com.kuka.resource.IResource resource)
Tries to create a facade of the specified type for the specified resource.

Parameters:
resource - The resource to create a facade for.
Returns:
A concrete facade of the specified type for the specified resource.

addListener

void addListener(FacadeListener<? super T> listener)
Parameters:
listener - A listener to be notified of resources going on- or offline in the pool.

removeListener

void removeListener(FacadeListener<? super T> listener)
Parameters:
listener - the listener to stop receiving notifications.


Copyright © 2019. All rights reserved.