Class ListenerInfo
java.lang.Object
org.apache.felix.http.base.internal.runtime.AbstractInfo<T>
org.apache.felix.http.base.internal.runtime.WhiteboardServiceInfo<EventListener>
org.apache.felix.http.base.internal.runtime.ListenerInfo
- All Implemented Interfaces:
Comparable<AbstractInfo<EventListener>>
Info object for registered listeners.
-
Constructor Summary
ConstructorDescriptionListenerInfo
(org.osgi.framework.ServiceReference<EventListener> ref) ConstructorListenerInfo
(org.osgi.framework.ServiceReference<EventListener> ref, Set<String> types, String[] dtos) Constructor -
Method Summary
Modifier and TypeMethodDescriptionString[]
The types as reported through the DTOsGet the registered listener typesgetType()
Get the type represented by this infoboolean
isListenerType
(String className) Is this listener of the required type?boolean
isSame
(AbstractInfo<EventListener> other) Compare two info objectsboolean
isValid()
Methods inherited from class org.apache.felix.http.base.internal.runtime.WhiteboardServiceInfo
getContextSelection, getContextSelectionFilter
Methods inherited from class org.apache.felix.http.base.internal.runtime.AbstractInfo
compareTo, equals, getBooleanProperty, getInitParams, getRanking, getService, getServiceId, getServiceReference, getStringArrayProperty, getStringProperty, getTarget, hashCode, isEmpty, isEmpty, ungetService
-
Constructor Details
-
ListenerInfo
Constructor- Parameters:
ref
- The service reference
-
ListenerInfo
public ListenerInfo(org.osgi.framework.ServiceReference<EventListener> ref, Set<String> types, String[] dtos) Constructor- Parameters:
ref
- The service referencetypes
- The listener typesdtos
- Optional dto types
-
-
Method Details
-
isValid
public boolean isValid()- Overrides:
isValid
in classWhiteboardServiceInfo<EventListener>
-
getDTOListenerTypes
The types as reported through the DTOs- Returns:
- Array of types
-
isListenerType
Is this listener of the required type?- Parameters:
className
- The listener type- Returns:
true
If the listener should be registered as that type
-
getListenerTypes
Get the registered listener types- Returns:
- The set of types
-
getType
Description copied from class:AbstractInfo
Get the type represented by this info- Specified by:
getType
in classAbstractInfo<EventListener>
- Returns:
- The type
-
isSame
Description copied from class:AbstractInfo
Compare two info objects- Overrides:
isSame
in classWhiteboardServiceInfo<EventListener>
-