Package com.tangosol.net.management
Class AnnotatedStandardEmitterMBean
java.lang.Object
javax.management.StandardMBean
javax.management.StandardEmitterMBean
com.tangosol.net.management.AnnotatedStandardEmitterMBean
- All Implemented Interfaces:
DynamicMBean
,MBeanRegistration
,NotificationBroadcaster
,NotificationEmitter
AnnotatedStandardEmitterMBean is an extension of a
StandardEmitterMBean
that uses the Description
and Notification
annotations
to describe the MBean and any attributes, operations and notifications it
declares.
The implementation of this class is basically identical to the
AnnotatedStandardMBean
class.
- Since:
- Coherence 12.1.2
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static class
A silentNotificationEmitter
implementation for all NotificationEmitter methods exceptgetNotificationInfo()
. -
Constructor Summary
ConstructorDescriptionAnnotatedStandardEmitterMBean
(T impl, Class<T> clzIface) Make a DynamicMBean out of the MBean implementation, using the specified mbeanInterface class. -
Method Summary
Modifier and TypeMethodDescriptionprotected String
Retrieve a description for a particular attribute by finding aDescription
annotation on the getter method for the attribute.protected String
getDescription
(MBeanInfo info) Retrieve the description for the MBean from the MBean interface annotation.protected String
Retrieve a description for the particularMBeanOperationInfo
by finding aDescription
annotation on the corresponding operation.protected String
getParameterName
(MBeanOperationInfo op, MBeanParameterInfo param, int iParam) Retrieve the parameter name for the specified parameter by finding aDescription
annotation on the operation.Methods inherited from class javax.management.StandardEmitterMBean
addNotificationListener, removeNotificationListener, removeNotificationListener, sendNotification
Methods inherited from class javax.management.StandardMBean
cacheMBeanInfo, getAttribute, getAttributes, getCachedMBeanInfo, getClassName, getConstructors, getDescription, getDescription, getDescription, getDescription, getImpact, getImplementation, getImplementationClass, getMBeanInfo, getMBeanInterface, getParameterName, invoke, postDeregister, postRegister, preDeregister, preRegister, setAttribute, setAttributes, setImplementation
-
Constructor Details
-
AnnotatedStandardEmitterMBean
Make a DynamicMBean out of the MBean implementation, using the specified mbeanInterface class.- Type Parameters:
T
- the type of the MBean implementation- Parameters:
impl
- the implementation of the MBeanclzIface
- the Management Interface implemented by the MBean's implementation. If null, then this object will use standard JMX design pattern to determine the management interface associated with the given implementation- Throws:
NotCompliantMBeanException
- if the mbeanInterface does not follow JMX design patterns for Management Interfaces, or if the provided implementation does not implement the specified interface
-
-
Method Details
-
getDescription
Retrieve the description for the MBean from the MBean interface annotation.- Overrides:
getDescription
in classStandardMBean
- Parameters:
info
- theMBeanInfo
for the MBean- Returns:
- the MBean description
-
getDescription
Retrieve a description for the particularMBeanOperationInfo
by finding aDescription
annotation on the corresponding operation.- Overrides:
getDescription
in classStandardMBean
- Parameters:
info
- theMBeanOperationInfo
- Returns:
- the description for an operation
-
getDescription
Retrieve a description for a particular attribute by finding aDescription
annotation on the getter method for the attribute. If a description is not found on the getter method, the setter will be checked.- Overrides:
getDescription
in classStandardMBean
- Parameters:
info
- theMBeanAttributeInfo
for the attribute- Returns:
- the description for an attribute
-
getParameterName
Retrieve the parameter name for the specified parameter by finding aDescription
annotation on the operation.- Overrides:
getParameterName
in classStandardMBean
- Parameters:
op
- theMBeanOperationInfo
for the opparam
- theMBeanParameterInfo
for the parameteriParam
- zero-based sequence number of the parameter- Returns:
- the name to use for the given MBeanParameterInfo.
-
getNotificationInfo
- Specified by:
getNotificationInfo
in interfaceNotificationBroadcaster
- Overrides:
getNotificationInfo
in classStandardEmitterMBean
-