|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmx4j.remote.rmi.ClientInvoker
public class ClientInvoker
An MBeanServerConnection that "converts" the MBeanServerConnection calls to RMIConnection
calls,
performing wrapping of parameters and/or the needed actions.
RMIConnectionInvoker
Constructor Summary | |
---|---|
ClientInvoker(javax.management.remote.rmi.RMIConnection rmiConnection,
RemoteNotificationClientHandler notificationHandler,
javax.security.auth.Subject delegate)
|
Method Summary | |
---|---|
void |
addNotificationListener(javax.management.ObjectName observed,
javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
Adds a NotificationListener to a registered MBean. |
void |
addNotificationListener(javax.management.ObjectName observed,
javax.management.ObjectName listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
Adds a NotificationListener to a registered MBean. |
javax.management.ObjectInstance |
createMBean(java.lang.String className,
javax.management.ObjectName objectName)
A facility method for createMBean(className, objectName, null, null) . |
javax.management.ObjectInstance |
createMBean(java.lang.String className,
javax.management.ObjectName objectName,
java.lang.Object[] args,
java.lang.String[] parameters)
Instantiates and registers an MBean of the specified class with the given ObjectName in the MBeanServer. |
javax.management.ObjectInstance |
createMBean(java.lang.String className,
javax.management.ObjectName objectName,
javax.management.ObjectName loaderName)
A facility method for createMBean(className, objectName, loaderName, null, null) . |
javax.management.ObjectInstance |
createMBean(java.lang.String className,
javax.management.ObjectName objectName,
javax.management.ObjectName loaderName,
java.lang.Object[] args,
java.lang.String[] parameters)
Instantiates and registers an MBean of the specified class with the given ObjectName in the MBeanServer. |
java.lang.Object |
getAttribute(javax.management.ObjectName objectName,
java.lang.String attribute)
Gets the value of the specified attribute of the named MBean. |
javax.management.AttributeList |
getAttributes(javax.management.ObjectName objectName,
java.lang.String[] attributes)
Gets the values of several attributes of the named MBean. |
java.lang.String |
getDefaultDomain()
Returns the default domain for this MBeanServer used in case ObjectName domain are not specified. |
java.lang.String[] |
getDomains()
Returns the list of different ObjectName domains under which the MBeans in this MBeanServer are registered. |
java.lang.Integer |
getMBeanCount()
Returns the number of MBeans registered in this MBeanServer. |
javax.management.MBeanInfo |
getMBeanInfo(javax.management.ObjectName objectName)
Returns the metadata information exposed for management about the named MBean. |
javax.management.ObjectInstance |
getObjectInstance(javax.management.ObjectName objectName)
Gets the ObjectInstance for the named MBean registered with the MBeanServer. |
java.lang.Object |
invoke(javax.management.ObjectName objectName,
java.lang.String methodName,
java.lang.Object[] args,
java.lang.String[] parameters)
Invokes the specified operation on the named MBean. |
boolean |
isInstanceOf(javax.management.ObjectName objectName,
java.lang.String className)
Returns whether the MBean specified is an instance of the specified class. |
boolean |
isRegistered(javax.management.ObjectName objectName)
Checks whether the given ObjectName identifies an MBean registered in this MBeanServer. |
java.util.Set |
queryMBeans(javax.management.ObjectName patternName,
javax.management.QueryExp filter)
Gets a subset of the ObjectInstances belonging to MBeans registered in this MBeanServer. |
java.util.Set |
queryNames(javax.management.ObjectName patternName,
javax.management.QueryExp filter)
Gets a subset of the ObjectNames belonging to MBeans registered in this MBeanServer. |
void |
removeNotificationListener(javax.management.ObjectName observed,
javax.management.NotificationListener listener)
Removes the specified listener from the named source MBean. |
void |
removeNotificationListener(javax.management.ObjectName observed,
javax.management.NotificationListener listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
Removes the specified listener from the named source MBean. |
void |
removeNotificationListener(javax.management.ObjectName observed,
javax.management.ObjectName listener)
Removes the specified listener MBean from the named source MBean. |
void |
removeNotificationListener(javax.management.ObjectName observed,
javax.management.ObjectName listener,
javax.management.NotificationFilter filter,
java.lang.Object handback)
Removes the specified listener MBean from the named source MBean. |
void |
setAttribute(javax.management.ObjectName objectName,
javax.management.Attribute attribute)
Sets the value of the specified attribute of the named MBean. |
javax.management.AttributeList |
setAttributes(javax.management.ObjectName objectName,
javax.management.AttributeList attributes)
Sets the values of several attributes of the named MBean. |
void |
unregisterMBean(javax.management.ObjectName objectName)
Unregisters the MBean with the specified ObjectName from this MBeanServer. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ClientInvoker(javax.management.remote.rmi.RMIConnection rmiConnection, RemoteNotificationClientHandler notificationHandler, javax.security.auth.Subject delegate)
Method Detail |
---|
public void addNotificationListener(javax.management.ObjectName observed, javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
addNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be added.listener
- The listener which will handle the notifications emitted by the source MBean.filter
- The filter which will allow the notification to be forwarded to the listener.handback
- The context to be sent to the listener when a notification is emitted.
javax.management.InstanceNotFoundException
- If the source MBean is not registered in the MBeanServer.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.removeNotificationListener(ObjectName, NotificationListener, NotificationFilter, Object)
public void removeNotificationListener(javax.management.ObjectName observed, javax.management.NotificationListener listener) throws javax.management.InstanceNotFoundException, javax.management.ListenerNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
removeNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be removed.listener
- The listener to be removed.
javax.management.InstanceNotFoundException
- If the source MBean is not registered in the MBeanServer.
javax.management.ListenerNotFoundException
- If the listener is not registered in the MBean.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.addNotificationListener(ObjectName, NotificationListener, NotificationFilter, Object)
public void removeNotificationListener(javax.management.ObjectName observed, javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws javax.management.InstanceNotFoundException, javax.management.ListenerNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
removeNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be removed.listener
- The listener to be removed.filter
- The filter that was specified when the listener was added.handback
- The handback that was specified when the listener was added.
javax.management.InstanceNotFoundException
- If the source MBean is not registered in the MBeanServer.
javax.management.ListenerNotFoundException
- If the listener (along with filter and handback) is not registered in the MBean.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.addNotificationListener(ObjectName, NotificationListener, NotificationFilter, Object)
public void addNotificationListener(javax.management.ObjectName observed, javax.management.ObjectName listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
addNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be added.listener
- The ObjectName of the listener MBean which will handle the notifications emitted by the source MBean.filter
- The filter which will allow the notification to be forwarded to the listener.handback
- The context to be sent to the listener when a notification is emitted.
javax.management.InstanceNotFoundException
- If the source or listener MBean are not registered in the MBeanServer.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.removeNotificationListener(ObjectName, ObjectName, NotificationFilter, Object)
public void removeNotificationListener(javax.management.ObjectName observed, javax.management.ObjectName listener) throws javax.management.InstanceNotFoundException, javax.management.ListenerNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
removeNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be removed.listener
- The ObjectName of the listener MBean to be removed.
javax.management.InstanceNotFoundException
- If the source or listener MBean are not registered in the MBeanServer.
javax.management.ListenerNotFoundException
- The listener is not registered in the MBean.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.addNotificationListener(ObjectName, ObjectName, NotificationFilter, Object)
public void removeNotificationListener(javax.management.ObjectName observed, javax.management.ObjectName listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws javax.management.InstanceNotFoundException, javax.management.ListenerNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
removeNotificationListener
in interface javax.management.MBeanServerConnection
observed
- The ObjectName of the source MBean on which the listener should be removed.listener
- The ObjectName of the listener MBean to be removed.filter
- The filter that was specified when the listener was added.handback
- The handback that was specified when the listener was added.
javax.management.InstanceNotFoundException
- If the source MBean is not registered in the MBeanServer.
javax.management.ListenerNotFoundException
- If the listener (along with filter and handback) is not registered in the MBean.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.addNotificationListener(ObjectName, NotificationListener, NotificationFilter, Object)
public javax.management.MBeanInfo getMBeanInfo(javax.management.ObjectName objectName) throws javax.management.InstanceNotFoundException, javax.management.IntrospectionException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
getMBeanInfo
in interface javax.management.MBeanServerConnection
objectName
- The name of the MBean for which retrieve the metadata.
javax.management.InstanceNotFoundException
- If the named MBean is not registered in the MBeanServer.
javax.management.IntrospectionException
- If an exception occured during introspection of the MBean.
javax.management.ReflectionException
- If a reflection-type exception occurred
java.io.IOException
- If a communication problem occurred.public boolean isInstanceOf(javax.management.ObjectName objectName, java.lang.String className) throws javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
isInstanceOf
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean.className
- The name of the class.
javax.management.InstanceNotFoundException
- If the named MBean is not registered in the MBeanServer.
java.io.IOException
- If a communication problem occurred.public java.lang.String[] getDomains() throws java.io.IOException
javax.management.MBeanServerConnection
getDomains
in interface javax.management.MBeanServerConnection
java.io.IOException
- If a communication problem occurred.public java.lang.String getDefaultDomain() throws java.io.IOException
javax.management.MBeanServerConnection
getDefaultDomain
in interface javax.management.MBeanServerConnection
java.io.IOException
- If a communication problem occurred.public javax.management.ObjectInstance createMBean(java.lang.String className, javax.management.ObjectName objectName) throws javax.management.ReflectionException, javax.management.InstanceAlreadyExistsException, javax.management.MBeanRegistrationException, javax.management.MBeanException, javax.management.NotCompliantMBeanException, java.io.IOException
javax.management.MBeanServerConnection
createMBean(className, objectName, null, null)
.
createMBean
in interface javax.management.MBeanServerConnection
javax.management.ReflectionException
javax.management.InstanceAlreadyExistsException
javax.management.MBeanRegistrationException
javax.management.MBeanException
javax.management.NotCompliantMBeanException
java.io.IOException
MBeanServerConnection.createMBean(String, ObjectName, Object[], String[])
public javax.management.ObjectInstance createMBean(java.lang.String className, javax.management.ObjectName objectName, java.lang.Object[] args, java.lang.String[] parameters) throws javax.management.ReflectionException, javax.management.InstanceAlreadyExistsException, javax.management.MBeanRegistrationException, javax.management.MBeanException, javax.management.NotCompliantMBeanException, java.io.IOException
javax.management.MBeanServerConnection
MBeanRegistration
createMBean
in interface javax.management.MBeanServerConnection
className
- The class name of the MBean to be instantiated.objectName
- The ObjectName of the MBean, may be null.args
- An array containing the arguments to pass to the constructor.parameters
- An array containing the signature of the constructor.
javax.management.ReflectionException
- If a reflection exception is thrown.
javax.management.InstanceAlreadyExistsException
- If another MBean with the same ObjectName is already registered in the MBeanServer.
javax.management.MBeanRegistrationException
- If an exception is thrown during MBean's registration.
javax.management.MBeanException
- If the constructor of the MBean has thrown an exception
javax.management.NotCompliantMBeanException
- If the MBean is not a JMX compliant MBean
java.io.IOException
- If a communication problem occurred.public javax.management.ObjectInstance createMBean(java.lang.String className, javax.management.ObjectName objectName, javax.management.ObjectName loaderName) throws javax.management.ReflectionException, javax.management.InstanceAlreadyExistsException, javax.management.MBeanRegistrationException, javax.management.MBeanException, javax.management.NotCompliantMBeanException, javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
createMBean(className, objectName, loaderName, null, null)
.
createMBean
in interface javax.management.MBeanServerConnection
javax.management.ReflectionException
javax.management.InstanceAlreadyExistsException
javax.management.MBeanRegistrationException
javax.management.MBeanException
javax.management.NotCompliantMBeanException
javax.management.InstanceNotFoundException
java.io.IOException
MBeanServerConnection.createMBean(String, ObjectName, ObjectName, Object[], String[])
public javax.management.ObjectInstance createMBean(java.lang.String className, javax.management.ObjectName objectName, javax.management.ObjectName loaderName, java.lang.Object[] args, java.lang.String[] parameters) throws javax.management.ReflectionException, javax.management.InstanceAlreadyExistsException, javax.management.MBeanRegistrationException, javax.management.MBeanException, javax.management.NotCompliantMBeanException, javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
MBeanRegistration
createMBean
in interface javax.management.MBeanServerConnection
className
- The class name of the MBean to be instantiated.objectName
- The ObjectName of the MBean, may be null.loaderName
- The ObjectName of the classloader MBean to be used.args
- An array containing the arguments to pass to the constructor.parameters
- An array containing the signature of the constructor.
javax.management.ReflectionException
- If a reflection exception is thrown.
javax.management.InstanceAlreadyExistsException
- If another MBean with the same ObjectName is already registered in the MBeanServer.
javax.management.MBeanRegistrationException
- If an exception is thrown during MBean's registration.
javax.management.MBeanException
- If the constructor of the MBean has thrown an exception
javax.management.NotCompliantMBeanException
- If the MBean is not a JMX compliant MBean
javax.management.InstanceNotFoundException
- If the specified classloader MBean is not registered in the MBeanServer.
java.io.IOException
- If a communication problem occurred.public void unregisterMBean(javax.management.ObjectName objectName) throws javax.management.InstanceNotFoundException, javax.management.MBeanRegistrationException, java.io.IOException
javax.management.MBeanServerConnection
unregisterMBean
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean to be unregistered.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.MBeanRegistrationException
- If an exception is thrown during MBean's unregistration.
java.io.IOException
- If a communication problem occurred.public java.lang.Object getAttribute(javax.management.ObjectName objectName, java.lang.String attribute) throws javax.management.MBeanException, javax.management.AttributeNotFoundException, javax.management.InstanceNotFoundException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
getAttribute
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean from which the attribute is to be retrieved.attribute
- The attribute name.
javax.management.MBeanException
- If the MBean's getter method throws an exception.
javax.management.AttributeNotFoundException
- If the specified attribute does not belong to the management interface of the MBean.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.ReflectionException
- If a reflection exception is thrown.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.setAttribute(javax.management.ObjectName, javax.management.Attribute)
public void setAttribute(javax.management.ObjectName objectName, javax.management.Attribute attribute) throws javax.management.InstanceNotFoundException, javax.management.AttributeNotFoundException, javax.management.InvalidAttributeValueException, javax.management.MBeanException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
setAttribute
in interface javax.management.MBeanServerConnection
objectName
- The name of the MBean within which the attribute is to be set.attribute
- The Attribute to be set.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.AttributeNotFoundException
- If the specified attribute does not belong to the management interface of the MBean.
javax.management.InvalidAttributeValueException
- If the value specified for the attribute does not match the attribute's type
javax.management.MBeanException
- If the MBean's setter method throws an exception.
javax.management.ReflectionException
- If a reflection exception is thrown.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.getAttribute(javax.management.ObjectName, java.lang.String)
public javax.management.AttributeList getAttributes(javax.management.ObjectName objectName, java.lang.String[] attributes) throws javax.management.InstanceNotFoundException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
getAttributes
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean from which the attributes are to be retrieved.attributes
- The attribute names.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.ReflectionException
- If a reflection exception is thrown.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.setAttributes(javax.management.ObjectName, javax.management.AttributeList)
public javax.management.AttributeList setAttributes(javax.management.ObjectName objectName, javax.management.AttributeList attributes) throws javax.management.InstanceNotFoundException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
setAttributes
in interface javax.management.MBeanServerConnection
objectName
- The name of the MBean within which the attribute is to be set.attributes
- The AttributeList containing the Attributes to be set.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.ReflectionException
- If a reflection exception is thrown.
java.io.IOException
- If a communication problem occurred.MBeanServerConnection.getAttributes(javax.management.ObjectName, java.lang.String[])
public java.lang.Object invoke(javax.management.ObjectName objectName, java.lang.String methodName, java.lang.Object[] args, java.lang.String[] parameters) throws javax.management.InstanceNotFoundException, javax.management.MBeanException, javax.management.ReflectionException, java.io.IOException
javax.management.MBeanServerConnection
invoke
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean on which the method is to be invoked.methodName
- The name of the operation to be invoked.args
- An array containing the arguments to pass to the operation.parameters
- An array containing the signature of the operation.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
javax.management.MBeanException
- If the MBean's operation method throws an exception.
javax.management.ReflectionException
- If a reflection exception is thrown.
java.io.IOException
- If a communication problem occurred.public java.lang.Integer getMBeanCount() throws java.io.IOException
javax.management.MBeanServerConnection
getMBeanCount
in interface javax.management.MBeanServerConnection
java.io.IOException
- If a communication problem occurred.public boolean isRegistered(javax.management.ObjectName objectName) throws java.io.IOException
javax.management.MBeanServerConnection
isRegistered
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName to be checked.
java.io.IOException
- If a communication problem occurred.public javax.management.ObjectInstance getObjectInstance(javax.management.ObjectName objectName) throws javax.management.InstanceNotFoundException, java.io.IOException
javax.management.MBeanServerConnection
getObjectInstance
in interface javax.management.MBeanServerConnection
objectName
- The ObjectName of the MBean.
javax.management.InstanceNotFoundException
- If the specified MBean is not registered in the MBeanServer.
java.io.IOException
- If a communication problem occurred.public java.util.Set queryMBeans(javax.management.ObjectName patternName, javax.management.QueryExp filter) throws java.io.IOException
javax.management.MBeanServerConnection
queryMBeans
in interface javax.management.MBeanServerConnection
patternName
- The ObjectName pattern identifying the MBeans to be retrieved, or null to retrieve all MBeans.filter
- The query expression to be evaluated for selecting MBeans, or null.
java.io.IOException
- If a communication problem occurred.public java.util.Set queryNames(javax.management.ObjectName patternName, javax.management.QueryExp filter) throws java.io.IOException
javax.management.MBeanServerConnection
queryNames
in interface javax.management.MBeanServerConnection
patternName
- The ObjectName pattern identifying the MBeans to be retrieved, or null to retrieve all MBeans.filter
- The query expression to be evaluated for selecting MBeans, or null.
java.io.IOException
- If a communication problem occurred.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |