ch.syabru.nagios.broker.jmx
Class JmxMessageListener

java.lang.Object
  extended by ch.syabru.nagios.broker.jmx.JmxMessageListener
All Implemented Interfaces:
MessageListener, EventListener, NotificationListener

public class JmxMessageListener
extends Object
implements MessageListener, NotificationListener

JMX message listener implementation.

Author:
Felix Roethenbacher

Constructor Summary
JmxMessageListener(MessageListenerManager messageListenerManager, MessageHandler messageHandler, JMXServiceURL jmxServiceUrl, ObjectName objectName)
          C'tor.
 
Method Summary
 String getId()
          Get message listener id.
 void handleNotification(Notification notification, Object handback)
           
 void registerListener()
          Register listener.
 void unregisterListener()
          Remove notification listeners.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JmxMessageListener

public JmxMessageListener(MessageListenerManager messageListenerManager,
                          MessageHandler messageHandler,
                          JMXServiceURL jmxServiceUrl,
                          ObjectName objectName)
C'tor.

Parameters:
messageListenerManager - Message listener manager.
messageHandler - Message handler.
jmxServiceUrl - JMX service URL.
objectName - Object name.
Method Detail

getId

public String getId()
Description copied from interface: MessageListener
Get message listener id.

Specified by:
getId in interface MessageListener
Returns:
Message listener id.

registerListener

public void registerListener()
Description copied from interface: MessageListener
Register listener.

Specified by:
registerListener in interface MessageListener

unregisterListener

public void unregisterListener()
Remove notification listeners.

Specified by:
unregisterListener in interface MessageListener

handleNotification

public void handleNotification(Notification notification,
                               Object handback)
Specified by:
handleNotification in interface NotificationListener


Copyright © 2010-2011 Syabru. All Rights Reserved.