Interface WireAdminListener
-
public interface WireAdminListener
Listener for Wire Admin Events.WireAdminListener
objects are registered with the Framework service registry and are notified with aWireAdminEvent
object when an event is broadcast.WireAdminListener
objects can inspect the receivedWireAdminEvent
object to determine its type, theWire
object with which it is associated, and the Wire Admin service that broadcasts the event.WireAdminListener
objects must be registered with a service propertyWireConstants.WIREADMIN_EVENTS
whose value is a bitwise OR of all the event types the listener is interested in receiving.For example:
Integer mask = Integer.valueOf(WIRE_TRACE | WIRE_CONNECTED | WIRE_DISCONNECTED); Hashtable ht = new Hashtable(); ht.put(WIREADMIN_EVENTS, mask); context.registerService(WireAdminListener.class.getName(), this, ht);
If aWireAdminListener
object is registered without a service propertyWireConstants.WIREADMIN_EVENTS
, then theWireAdminListener
will receive no events.Security Considerations. Bundles wishing to monitor
WireAdminEvent
objects will requireServicePermission[WireAdminListener,REGISTER]
to register aWireAdminListener
service. SinceWireAdminEvent
objects containWire
objects, care must be taken in assigning permission to register aWireAdminListener
service.- See Also:
WireAdminEvent
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
wireAdminEvent(WireAdminEvent event)
Receives notification of a broadcastWireAdminEvent
object.
-
-
-
Method Detail
-
wireAdminEvent
void wireAdminEvent(WireAdminEvent event)
Receives notification of a broadcastWireAdminEvent
object. The event object will be of an event type specified in thisWireAdminListener
service'sWireConstants.WIREADMIN_EVENTS
service property.- Parameters:
event
- TheWireAdminEvent
object.
-
-