org.ow2.jonas.ee.mejb
Class ListenerRegistrationImpl

java.lang.Object
  extended by org.ow2.jonas.ee.mejb.ListenerRegistrationImpl
All Implemented Interfaces:
Serializable, ListenerRegistration

public class ListenerRegistrationImpl
extends Object
implements ListenerRegistration

ListenerRegistration implementation.

See Also:
Serialized Form

Constructor Summary
ListenerRegistrationImpl(MBeanServerConnection connection)
          A ListenerRegistration object allows to ad/remove listeners to notifications emitted by MBeans which are registered in a remote MBeanServer.
 
Method Summary
 void addNotificationListener(ObjectName name, NotificationListener listener, NotificationFilter filter, Object o)
          Add notification listener.
 void removeNotificationListener(ObjectName name, NotificationListener listener)
          Remove notification listener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListenerRegistrationImpl

public ListenerRegistrationImpl(MBeanServerConnection connection)
A ListenerRegistration object allows to ad/remove listeners to notifications emitted by MBeans which are registered in a remote MBeanServer.

Parameters:
connection - the remote MBean server
Method Detail

addNotificationListener

public void addNotificationListener(ObjectName name,
                                    NotificationListener listener,
                                    NotificationFilter filter,
                                    Object o)
                             throws InstanceNotFoundException,
                                    RemoteException
Add notification listener.

Specified by:
addNotificationListener in interface ListenerRegistration
Parameters:
name - identifies the emitter MBean
listener - the listener to add
filter - the associated filter
o - the associated handback object
Throws:
InstanceNotFoundException - emitter MBean not registered in the MBeanServer
RemoteException - operation failed

removeNotificationListener

public void removeNotificationListener(ObjectName name,
                                       NotificationListener listener)
                                throws InstanceNotFoundException,
                                       ListenerNotFoundException,
                                       RemoteException
Remove notification listener

Specified by:
removeNotificationListener in interface ListenerRegistration
Parameters:
name - identifies the emitter MBean
listener - the listener to remove
Throws:
InstanceNotFoundException - emitter MBean not registered in the MBeanServer
ListenerNotFoundException - arg1 not registered as listener
RemoteException - operation failed


Copyright © 2010 OW2 Consortium. All Rights Reserved.