|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.commons.modeler.BaseNotificationBroadcaster
Implementation of NotificationBroadcaster
for attribute
change notifications. This class is used by BaseModelMBean
to
handle notifications of attribute change events to interested listeners.
Field Summary | |
protected java.util.ArrayList |
entries
The set of registered BaseNotificationBroadcasterEntry
entries. |
(package private) int[] |
hookCount
|
(package private) NotificationListener[][] |
hooks
|
Constructor Summary | |
BaseNotificationBroadcaster()
|
Method Summary | |
void |
addNotificationListener(NotificationListener listener,
NotificationFilter filter,
java.lang.Object handback)
Add a notification event listener to this MBean. |
MBeanNotificationInfo[] |
getNotificationInfo()
Return an MBeanNotificationInfo object describing the
notifications sent by this MBean. |
private void |
registerNotifications(FixedNotificationFilter filter)
|
void |
removeNotificationListener(NotificationListener listener)
Remove a notification event listener from this MBean. |
void |
removeNotificationListener(NotificationListener listener,
NotificationFilter filter,
java.lang.Object handback)
Remove a notification event listener from this MBean. |
void |
removeNotificationListener(NotificationListener listener,
java.lang.Object handback)
Remove a notification event listener from this MBean. |
void |
sendNotification(Notification notification)
Send the specified notification to all interested listeners. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.util.ArrayList entries
BaseNotificationBroadcasterEntry
entries.
NotificationListener[][] hooks
int[] hookCount
Constructor Detail |
public BaseNotificationBroadcaster()
Method Detail |
public void addNotificationListener(NotificationListener listener, NotificationFilter filter, java.lang.Object handback) throws java.lang.IllegalArgumentException
listener
- Listener that will receive event notificationsfilter
- Filter object used to filter event notifications
actually delivered, or null
for no filteringhandback
- Handback object to be sent along with event
notifications
java.lang.IllegalArgumentException
- if the listener parameter is nullpublic MBeanNotificationInfo[] getNotificationInfo()
MBeanNotificationInfo
object describing the
notifications sent by this MBean.
public void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
listener
- The listener to be removed (any and all registrations
for this listener will be eliminated)
ListenerNotFoundException
- if this listener is not
registered in the MBeanpublic void removeNotificationListener(NotificationListener listener, java.lang.Object handback) throws ListenerNotFoundException
listener
- The listener to be removed (any and all registrations
for this listener will be eliminated)handback
- Handback object to be sent along with event
notifications
ListenerNotFoundException
- if this listener is not
registered in the MBeanpublic void removeNotificationListener(NotificationListener listener, NotificationFilter filter, java.lang.Object handback) throws ListenerNotFoundException
listener
- The listener to be removed (any and all registrations
for this listener will be eliminated)filter
- Filter object used to filter event notifications
actually delivered, or null
for no filteringhandback
- Handback object to be sent along with event
notifications
ListenerNotFoundException
- if this listener is not
registered in the MBeanpublic void sendNotification(Notification notification)
notification
- The notification to be sentprivate void registerNotifications(FixedNotificationFilter filter)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |