public abstract class AbstractJMXConnector
extends java.lang.Object
implements javax.management.remote.JMXConnector, java.io.Serializable
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractJMXConnector(javax.management.remote.JMXServiceURL address)
Creates a new JMXConnector that will connect to the given JMXServiceURL
|
| Modifier and Type | Method and Description |
|---|---|
void |
addConnectionNotificationListener(javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback) |
void |
close() |
void |
connect() |
void |
connect(java.util.Map environment) |
protected ConnectionNotificationEmitter |
createConnectionNotificationEmitter()
Creates a notification emitter used to emit connection notifications.
|
protected abstract void |
doClose()
Template method to be implemented by subclasses to close this JMXConnector
|
protected abstract void |
doConnect(java.util.Map environment) |
protected abstract javax.management.MBeanServerConnection |
doGetMBeanServerConnection(javax.security.auth.Subject delegate)
Template method to be implemented by subclasses to return an MBeanServerConnection
for the given delegate subject.
|
protected javax.management.remote.JMXServiceURL |
getAddress()
Returns the JMXServiceURL this JMXConnector will connect to.
|
protected ConnectionNotificationEmitter |
getConnectionNotificationEmitter() |
javax.management.MBeanServerConnection |
getMBeanServerConnection() |
javax.management.MBeanServerConnection |
getMBeanServerConnection(javax.security.auth.Subject delegate) |
protected boolean |
isClosed()
Returns whether the
close() method has been called. |
protected boolean |
isConnected()
Returns whether the
connect() or connect(Map) method has been called on this JMXConnector. |
void |
removeConnectionNotificationListener(javax.management.NotificationListener listener) |
void |
removeConnectionNotificationListener(javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback) |
protected void |
sendConnectionNotificationClosed() |
protected AbstractJMXConnector(javax.management.remote.JMXServiceURL address)
throws java.io.IOException
java.io.IOExceptionprotected javax.management.remote.JMXServiceURL getAddress()
public void connect()
throws java.io.IOException,
java.lang.SecurityException
connect in interface javax.management.remote.JMXConnectorjava.io.IOExceptionjava.lang.SecurityExceptionpublic void connect(java.util.Map environment)
throws java.io.IOException,
java.lang.SecurityException
connect in interface javax.management.remote.JMXConnectorjava.io.IOExceptionjava.lang.SecurityExceptionprotected abstract void doConnect(java.util.Map environment)
throws java.io.IOException,
java.lang.SecurityException
java.io.IOExceptionjava.lang.SecurityExceptionpublic void close()
throws java.io.IOException
close in interface javax.management.remote.JMXConnectorjava.io.IOExceptionprotected abstract void doClose()
throws java.io.IOException
java.io.IOExceptionpublic javax.management.MBeanServerConnection getMBeanServerConnection()
throws java.io.IOException
getMBeanServerConnection in interface javax.management.remote.JMXConnectorjava.io.IOExceptionpublic javax.management.MBeanServerConnection getMBeanServerConnection(javax.security.auth.Subject delegate)
throws java.io.IOException
getMBeanServerConnection in interface javax.management.remote.JMXConnectorjava.io.IOExceptionprotected abstract javax.management.MBeanServerConnection doGetMBeanServerConnection(javax.security.auth.Subject delegate)
throws java.io.IOException
JMXConnection (or an equivalent client side connection object).
The JMXConnection object to which calls are delegated can in turn be a chain of
objects that decorate the call performing some other operation; the final object in
the chain is the one that really communicates with the server side, and it is normally
called java.io.IOExceptionpublic void addConnectionNotificationListener(javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
addConnectionNotificationListener in interface javax.management.remote.JMXConnectorpublic void removeConnectionNotificationListener(javax.management.NotificationListener listener)
throws javax.management.ListenerNotFoundException
removeConnectionNotificationListener in interface javax.management.remote.JMXConnectorjavax.management.ListenerNotFoundExceptionpublic void removeConnectionNotificationListener(javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
throws javax.management.ListenerNotFoundException
removeConnectionNotificationListener in interface javax.management.remote.JMXConnectorjavax.management.ListenerNotFoundExceptionprotected void sendConnectionNotificationClosed()
protected ConnectionNotificationEmitter createConnectionNotificationEmitter()
protected ConnectionNotificationEmitter getConnectionNotificationEmitter()
protected boolean isConnected()
connect() or connect(Map) method has been called on this JMXConnector.protected boolean isClosed()
close() method has been called.