|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.management.remote.generic.GenericConnector
public class GenericConnector
A client connection to a remote JMX API server. This class can
use a MessageConnection
object to specify the transport for
communicating with the server.
User code does not usually instantiate this class. Instead, a
JMXConnectorProvider
should be added to the JMXConnectorFactory
so that users can implicitly instantiate the
GenericConnector (or a subclass of it) through the JMXServiceURL
provided when connecting.
The specific connector protocol to be used by an instance of
this class is specified by attributes in the Map
passed to the constructor or the connect
method. The attribute MESSAGE_CONNECTION
is the standard
way to define the transport. An implementation can recognize other
attributes to define the transport differently.
Field Summary | |
---|---|
static String |
MESSAGE_CONNECTION
Name of the attribute that specifies how this connector sends messages to its connector server. |
static String |
OBJECT_WRAPPING
Name of the attribute that specifies the object wrapping for parameters whose deserialization requires special treatment. |
Fields inherited from interface javax.management.remote.JMXConnector |
---|
CREDENTIALS |
Constructor Summary | |
---|---|
GenericConnector()
Default no-arg constructor. |
|
GenericConnector(Map env)
Constructor specifying connection attributes. |
Method Summary | |
---|---|
void |
addConnectionNotificationListener(NotificationListener listener,
NotificationFilter filter,
Object handback)
|
void |
close()
|
void |
connect()
|
void |
connect(Map env)
|
String |
getConnectionId()
|
MBeanServerConnection |
getMBeanServerConnection()
|
MBeanServerConnection |
getMBeanServerConnection(Subject delegationSubject)
|
void |
removeConnectionNotificationListener(NotificationListener listener)
|
void |
removeConnectionNotificationListener(NotificationListener listener,
NotificationFilter filter,
Object handback)
|
protected void |
sendNotification(Notification n)
Send a notification to the connection listeners. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String OBJECT_WRAPPING
Name of the attribute that specifies the object wrapping for
parameters whose deserialization requires special treatment.
The value associated with this attribute, if any, must be an
object that implements the interface ObjectWrapping
.
public static final String MESSAGE_CONNECTION
Name of the attribute that specifies how this connector
sends messages to its connector server. The value associated
with this attribute, if any, must be an object that implements
the interface MessageConnection
.
Constructor Detail |
---|
public GenericConnector()
Default no-arg constructor.
public GenericConnector(Map env)
Constructor specifying connection attributes.
env
- the attributes of the connection.Method Detail |
---|
public void connect() throws IOException
connect
in interface JMXConnector
IOException
public void connect(Map env) throws IOException
connect
in interface JMXConnector
IOException
public String getConnectionId() throws IOException
getConnectionId
in interface JMXConnector
IOException
public MBeanServerConnection getMBeanServerConnection() throws IOException
getMBeanServerConnection
in interface JMXConnector
IOException
public MBeanServerConnection getMBeanServerConnection(Subject delegationSubject) throws IOException
getMBeanServerConnection
in interface JMXConnector
IOException
public void close() throws IOException
close
in interface JMXConnector
IOException
public void addConnectionNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
addConnectionNotificationListener
in interface JMXConnector
public void removeConnectionNotificationListener(NotificationListener listener) throws ListenerNotFoundException
removeConnectionNotificationListener
in interface JMXConnector
ListenerNotFoundException
public void removeConnectionNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback) throws ListenerNotFoundException
removeConnectionNotificationListener
in interface JMXConnector
ListenerNotFoundException
protected void sendNotification(Notification n)
Send a notification to the connection listeners. The
notification will be sent to every listener added with addConnectionNotificationListener
that was not subsequently
removed by a removeConnectionNotificationListener
,
provided the corresponding NotificationFilter
matches.
n
- the notification to send. This will usually be a
JMXConnectionNotification
, but an implementation can
send other notifications as well.
|
Open Source build 02 opendmk-1.0-b02 2007.10.01_19:17:46_MEST |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |