Package org.apache.felix.eventadmin.impl.handler

## Class EventHandlerTracker

- java.lang.Object
- - org.osgi.util.tracker.ServiceTracker<org.osgi.service.event.EventHandler,​EventHandlerProxy>
  - - org.apache.felix.eventadmin.impl.handler.EventHandlerTracker

All Implemented Interfaces:
  `org.osgi.util.tracker.ServiceTrackerCustomizer<org.osgi.service.event.EventHandler,​EventHandlerProxy>`

    public class EventHandlerTracker
    extends org.osgi.util.tracker.ServiceTracker<org.osgi.service.event.EventHandler,​EventHandlerProxy>

The event handler tracker keeps track of all event handler services.

Author:
  Felix Project Team

### Field Summary

### Fields inherited from class org.osgi.util.tracker.ServiceTracker

`context, filter`

### Constructor Summary

Constructors
`EventHandlerTracker​(org.osgi.framework.BundleContext context)`

### Method Summary

All Methods Instance Methods Concrete Methods
`EventHandlerProxy` `addingService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference)`
`Collection<EventHandlerProxy>` `getDeniedHandlers()` Get all handlers for this event
`Collection<EventHandlerProxy>` `getHandlers​(org.osgi.service.event.Event event)` Get all handlers for this event
`void` `modifiedService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference, EventHandlerProxy proxy)`
`void` `removedService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference, EventHandlerProxy proxy)`
`void` `update​(String[] ignoreTimeout, boolean requireTopic)` Update the timeout configuration.

### Methods inherited from class org.osgi.util.tracker.ServiceTracker

`close, getService, getService, getServiceReference, getServiceReferences, getServices, getServices, getTracked, getTrackingCount, isEmpty, open, open, remove, size, waitForService`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### EventHandlerTracker

    public EventHandlerTracker​(org.osgi.framework.BundleContext context)

### Method Detail

#### update

    public void update​(String[] ignoreTimeout,
                       boolean requireTopic)

Update the timeout configuration.

Parameters:
  `ignoreTimeout` - The configuration for ignoring timeout
  `requireTopic` - Is a topic required

#### addingService

    public EventHandlerProxy addingService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference)

Specified by:
  `addingService` in interface `org.osgi.util.tracker.ServiceTrackerCustomizer<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
Overrides:
  `addingService` in class `org.osgi.util.tracker.ServiceTracker<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
See Also:
  `ServiceTracker.addingService(org.osgi.framework.ServiceReference)`

#### modifiedService

    public void modifiedService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference,
                                EventHandlerProxy proxy)

Specified by:
  `modifiedService` in interface `org.osgi.util.tracker.ServiceTrackerCustomizer<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
Overrides:
  `modifiedService` in class `org.osgi.util.tracker.ServiceTracker<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
See Also:
  `ServiceTracker.modifiedService(org.osgi.framework.ServiceReference, java.lang.Object)`

#### removedService

    public void removedService​(org.osgi.framework.ServiceReference<org.osgi.service.event.EventHandler> reference,
                               EventHandlerProxy proxy)

Specified by:
  `removedService` in interface `org.osgi.util.tracker.ServiceTrackerCustomizer<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
Overrides:
  `removedService` in class `org.osgi.util.tracker.ServiceTracker<org.osgi.service.event.EventHandler,​EventHandlerProxy>`
See Also:
  `ServiceTracker.removedService(org.osgi.framework.ServiceReference, java.lang.Object)`

#### getHandlers

    public Collection<EventHandlerProxy> getHandlers​(org.osgi.service.event.Event event)

Get all handlers for this event

Parameters:
  `event` - The event topic
Returns:
  All handlers for the event

#### getDeniedHandlers

    public Collection<EventHandlerProxy> getDeniedHandlers()

Get all handlers for this event

Returns:
  All handlers for the event