DynamicMBean (Java SE 16 & JDK 16) (original) (raw)
All Known Subinterfaces:
[DiagnosticCommandMBean](../../../jdk.management/com/sun/management/DiagnosticCommandMBean.html "interface in com.sun.management")
, [ModelMBean](modelmbean/ModelMBean.html "interface in javax.management.modelmbean")
All Known Implementing Classes:
[RequiredModelMBean](modelmbean/RequiredModelMBean.html "class in javax.management.modelmbean")
, [StandardEmitterMBean](StandardEmitterMBean.html "class in javax.management")
, [StandardMBean](StandardMBean.html "class in javax.management")
public interface DynamicMBean
Defines the methods that should be implemented by a Dynamic MBean (MBean that exposes a dynamic management interface).
Since:
1.5
Method Summary
Obtain the value of a specific attribute of the Dynamic MBean.
Get the values of several attributes of the Dynamic MBean.
Provides the exposed attributes and actions of the Dynamic MBean using an MBeanInfo object.
Allows an action to be invoked on the Dynamic MBean.void
Set the value of a specific attribute of the Dynamic MBean.
Sets the values of several attributes of the Dynamic MBean.
Method Details
getAttribute
Obtain the value of a specific attribute of the Dynamic MBean.
Parameters:
attribute
- The name of the attribute to be retrieved
Returns:
The value of the attribute retrieved.
Throws:
[AttributeNotFoundException](AttributeNotFoundException.html "class in javax.management")
- if specified attribute does not exist or cannot be retrieved
[MBeanException](MBeanException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown by the MBean's getter.
[ReflectionException](ReflectionException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown while trying to invoke the getter.
See Also:
setAttribute(javax.management.Attribute)setAttribute
Set the value of a specific attribute of the Dynamic MBean.
Parameters:
attribute
- The identification of the attribute to be set and the value it is to be set to.
Throws:
[AttributeNotFoundException](AttributeNotFoundException.html "class in javax.management")
- if specified attribute does not exist or cannot be retrieved
[InvalidAttributeValueException](InvalidAttributeValueException.html "class in javax.management")
- if value specified is not valid for the attribute
[MBeanException](MBeanException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown by the MBean's setter.
[ReflectionException](ReflectionException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown while trying to invoke the MBean's setter.
See Also:
getAttribute(java.lang.String)getAttributes
Get the values of several attributes of the Dynamic MBean.
Parameters:
attributes
- A list of the attributes to be retrieved.
Returns:
The list of attributes retrieved.
See Also:
setAttributes(javax.management.AttributeList)setAttributes
Sets the values of several attributes of the Dynamic MBean.
Parameters:
attributes
- A list of attributes: The identification of the attributes to be set and the values they are to be set to.
Returns:
The list of attributes that were set, with their new values.
See Also:
getAttributes(java.lang.String[])invoke
Allows an action to be invoked on the Dynamic MBean.
Parameters:
actionName
- The name of the action to be invoked.
params
- An array containing the parameters to be set when the action is invoked.
signature
- An array containing the signature of the action. The class objects will be loaded through the same class loader as the one used for loading the MBean on which the action is invoked.
Returns:
The object returned by the action, which represents the result of invoking the action on the MBean specified.
Throws:
[MBeanException](MBeanException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown by the MBean's invoked method.
[ReflectionException](ReflectionException.html "class in javax.management")
- Wraps ajava.lang.Exception
thrown while trying to invoke the methodgetMBeanInfo
Provides the exposed attributes and actions of the Dynamic MBean using an MBeanInfo object.
Returns:
An instance ofMBeanInfo
allowing all attributes and actions exposed by this Dynamic MBean to be retrieved.