javax.management
Interface NotificationBroadcaster
- All Known Subinterfaces:
- ModelMBean, ModelMBeanNotificationBroadcaster
- All Known Implementing Classes:
- MBeanServerDelegate, NotificationBroadcasterSupport, DefaultDynamicMBean, AbstractAdaptor
- public interface NotificationBroadcaster
Should be implemented by an MBean that emits Notifications. It allows a
listener to be registered within the MBean as notification listener.
addNotificationListener
public void addNotificationListener(NotificationListener listener,
NotificationFilter filter,
java.lang.Object handback)
throws java.lang.IllegalArgumentException
- Enables a couple (listener,handback) for a registered MBean to be added.
- Parameters:
listener
- The listener object which will handles notifications
emitted by the registered MBean.filter
- The filter object. If not specified, no filtering will be
performed before handling notifications.handback
- The context to be sent to the listener when a
notification is emitted.- Throws:
java.lang.IllegalArgumentException
- Listener parameter is null.
removeNotificationListener
public void removeNotificationListener(NotificationListener listener)
throws ListenerNotFoundException
- Enables a listener for an MBean to be removed. All couple
(listener, handback) are removed.
- Parameters:
listener
- The listener object which will handles notifications
emitted by the registered MBean.- Throws:
ListenerNotFoundException
- The listener is not registered in the MBean.
getNotificationInfo
public MBeanNotificationInfo[] getNotificationInfo()
- Returns a NotificationInfo object containing the name of the Java class
of the notification and the notification types sent.
- Returns:
- This returns a array of MBeanNotificationInfo which
contains the notification information
Copyright ©2003 XMOJO.org. All Rights Reserved.