Package org.rribbit.retrieval
Interface ListenerObjectRetriever
- All Known Implementing Classes:
CachedListenerObjectRetriever,DefaultListenerObjectRetriever
public interface ListenerObjectRetriever
A
ListenerObjectRetriever retrieves the ListenerObjects that were created by one or more ListenerObjectCreators.- Author:
- G.J. Schouten
-
Method Summary
Modifier and TypeMethodDescriptiongetListenerObjects(Class<?> returnType) Returns aCollectionofListenerObjects that satisfy the following requirements.getListenerObjects(Class<?> returnType, String hint) Returns aCollectionofListenerObjects that satisfy the following requirements.getListenerObjects(String hint) Returns aCollectionofListenerObjects that satisfy the following requirements.
-
Method Details
-
getListenerObjects
Collection<ListenerObject> getListenerObjects()- Returns:
- a
Collectionof all knownListenerObjects, or an emptyCollectionif there are none. This method never returns null.
-
getListenerObjects
Returns aCollectionofListenerObjects that satisfy the following requirements.- The parameter 'returnType' is assignable from the returntype of the
ListenerObject
- Parameters:
returnType- the return type that has to be assignable from the returntype of eachListenerObject- Returns:
- a
CollectionofListenerObjects that satisfy the above requirements, or an emptyCollectionif there were no matches. This method never returns null. - Throws:
IllegalArgumentException- when 'returnType' is 'null'
- The parameter 'returnType' is assignable from the returntype of the
-
getListenerObjects
Returns aCollectionofListenerObjects that satisfy the following requirements.- The hints of the
ListenerObjectmust contain the 'hint' parameter
- Parameters:
hint- the hint that has to be contained by the hints of eachListenerObject- Returns:
- a
CollectionofListenerObjects that satisfy the above requirements, or an emptyCollectionif there were no matches. This method never returns null. - Throws:
IllegalArgumentException- when 'hint' is 'null'
- The hints of the
-
getListenerObjects
Returns aCollectionofListenerObjects that satisfy the following requirements.- The parameter 'returnType' is assignable from the returntype of the
ListenerObject - The hints of the
ListenerObjectmust contain the 'hint' parameter
- Parameters:
returnType- the return type that has to be assignable from the returntype of eachListenerObjecthint- the hint that has to be contained by the hints of eachListenerObject- Returns:
- a
CollectionofListenerObjects that satisfy the above requirements, or an emptyCollectionif there were no matches. This method never returns null. - Throws:
IllegalArgumentException- when 'returnType' or 'hint' is 'null'
- The parameter 'returnType' is assignable from the returntype of the
-