- All Superinterfaces:
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@ConsumerType @FunctionalInterface public interface UnfilteredServiceListener extends ServiceListenerA
ServiceEventlistener that does not filter based upon any filter string specified to
BundleContext.addServiceListener(ServiceListener, String). Using an
UnfilteredServiceListenerand specifying a filter string to
BundleContext.addServiceListener(ServiceListener, String)allows the listener to receive all
ServiceEventobjects while still advising
ListenerHookimplementation of the service interests in the filter string. For example, an implementation of Declarative Services would add an
UnfilteredServiceListenerwith a filter string listing all the services referenced by all the service components. The Declarative Services implementation would receive all
ServiceEventobjects for internal processing and a Remote Services discovery service implementation can observe the service interests of the service components using a
ListenerHook. When the set of service components being processed changes, the Declarative Services implementation would re-add the
UnfilteredServiceListenerwith an updated filter string.
ServiceEventis fired, it is synchronously delivered to an
UnfilteredServiceListener. The Framework may deliver
ServiceEventobjects to an
UnfilteredServiceListenerout of order and may concurrently call and/or reenter an
UnfilteredServiceListenerobject is registered with the Framework using the
UnfilteredServiceListenerobjects are called with a
ServiceEventobject when a service is registered, modified, or is in the process of unregistering.
ServiceEventobject delivery to
UnfilteredServiceListenerobjects are not filtered by the filter specified when the listener was registered. If the Java Runtime Environment supports permissions, then some filtering is done.
ServiceEventobjects are only delivered to the listener if the bundle which defines the listener object's class has the appropriate
ServicePermissionto get the service using at least one of the named classes under which the service was registered.