|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.granite.jmx.OpenMBean
public class OpenMBean
The OpenMBean class wraps an instance of any bean and introspects its properties and methods
for MBeanAttributes and MBeanOperations. It implements all functionalities required by a
DynamicMBean and returns an OpenMBeanInfo object.
Limitations:
SimpleType and ArrayType are supported (no composite type).
| Constructor Summary | |
|---|---|
protected |
OpenMBean()
Creates a new OpenMBean instance and instrospects its child class for attributes and operations. |
| Method Summary | |
|---|---|
static OpenMBean |
createMBean(Class<?> beanClass,
Object instance)
Creates a new OpenMBean by introspecting the beanClass parameter and wrapping the instance parameter. |
static OpenMBean |
createMBean(Object instance)
Creates a new OpenMBean by introspecting and wrapping the instance parameter. |
Object |
getAttribute(String attribute)
|
AttributeList |
getAttributes(String[] names)
|
MBeanInfo |
getMBeanInfo()
|
Object |
invoke(String actionName,
Object[] params,
String[] signature)
|
void |
setAttribute(Attribute attribute)
|
AttributeList |
setAttributes(AttributeList attributes)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected OpenMBean()
| Method Detail |
|---|
public static OpenMBean createMBean(Object instance)
instance - an instance of a bean to introspect.
public static OpenMBean createMBean(Class<?> beanClass,
Object instance)
beanClass - a class (or interface) used for introspection.instance - the bean to encapsulate.
IllegalArgumentException - if instance is not an instance of beanClass.
public Object getAttribute(String attribute)
throws AttributeNotFoundException,
MBeanException,
ReflectionException
getAttribute in interface DynamicMBeanAttributeNotFoundException
MBeanException
ReflectionExceptionpublic AttributeList getAttributes(String[] names)
getAttributes in interface DynamicMBeanpublic MBeanInfo getMBeanInfo()
getMBeanInfo in interface DynamicMBean
public Object invoke(String actionName,
Object[] params,
String[] signature)
throws MBeanException,
ReflectionException
invoke in interface DynamicMBeanMBeanException
ReflectionException
public void setAttribute(Attribute attribute)
throws AttributeNotFoundException,
InvalidAttributeValueException,
MBeanException,
ReflectionException
setAttribute in interface DynamicMBeanAttributeNotFoundException
InvalidAttributeValueException
MBeanException
ReflectionExceptionpublic AttributeList setAttributes(AttributeList attributes)
setAttributes in interface DynamicMBean
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||