Package org.ametys.core.mbean
Class AbstractAmetysDynamicMBean
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.core.mbean.AbstractAmetysDynamicMBean
- All Implemented Interfaces:
DynamicMBean,LogEnabled
- Direct Known Subclasses:
CacheUsageMBean,JackrabbitMBean
Abstract class for Ametys Dynamic MBean.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Object_getAttribute(String attributeName) Get the value of the attribute.getAttribute(String attributeName) getAttributes(String[] attributeNames) protected abstract MBeanAttributeInfo[]Get the definition of the attributes exposed by the MBean.protected MBeanConstructorInfo[]Get the definition of the constructors exposed by the MBean.protected abstract StringGet the description of the MBeanprotected abstract StringGet the human readable name of the MBean.protected MBeanNotificationInfo[]Get the definition of the notification exposed by the MBeanprotected MBeanOperationInfo[]Get the definition of the operation methods exposed by the MBeanvoidsetAttribute(Attribute attribute) setAttributes(AttributeList attributes) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
_mBeanInfo
The MBean metadata
-
-
Constructor Details
-
AbstractAmetysDynamicMBean
public AbstractAmetysDynamicMBean()AbstractAmetysDynamicMBean basic constructor. Generate the MBean info.
-
-
Method Details
-
getAttribute
- Specified by:
getAttributein interfaceDynamicMBean- Throws:
AttributeNotFoundException
-
_getAttribute
Get the value of the attribute. This method should assume that attributeName is not null. And return null if the name is not recognized- Parameters:
attributeName- the name of the attribute- Returns:
- the value of the attribute
-
getAttributes
- Specified by:
getAttributesin interfaceDynamicMBean
-
invoke
public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException - Specified by:
invokein interfaceDynamicMBean- Throws:
MBeanExceptionReflectionException
-
setAttribute
public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException - Specified by:
setAttributein interfaceDynamicMBean- Throws:
AttributeNotFoundExceptionInvalidAttributeValueExceptionMBeanExceptionReflectionException
-
setAttributes
- Specified by:
setAttributesin interfaceDynamicMBean
-
getMBeanInfo
- Specified by:
getMBeanInfoin interfaceDynamicMBean
-
getMBeanName
Get the human readable name of the MBean. This name will be exposed.- Returns:
- the name
-
getMBeanDescription
Get the description of the MBean- Returns:
- the description
-
getMBeanAttributes
Get the definition of the attributes exposed by the MBean.- Returns:
- the attributes information
-
getMBeanConstructorInfo
Get the definition of the constructors exposed by the MBean.- Returns:
- the constructors information
-
getMBeanOperationInfo
Get the definition of the operation methods exposed by the MBean- Returns:
- the operations information
-
getMBeanNotificationInfo
Get the definition of the notification exposed by the MBean- Returns:
- the notification information
-