T - the type of the managed objectpublic class ObjectMBean<T> extends Object implements ModelMBean, MBeanRegistration
ModelMBean wrapper implementation for a POJO.| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOGGER |
| Constructor and Description |
|---|
ObjectMBean(T source)
Creates a new instance with the specified POJO.
|
public ObjectMBean(T source)
source - The original POJOpublic static Object getSource(ObjectName oname)
oname - The object namepublic final Object getAttribute(String fqan) throws AttributeNotFoundException, MBeanException, ReflectionException
getAttribute in interface DynamicMBeanAttributeNotFoundExceptionMBeanExceptionReflectionExceptionpublic final void setAttribute(Attribute attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
setAttribute in interface DynamicMBeanAttributeNotFoundExceptionMBeanExceptionReflectionExceptionpublic final Object invoke(String name, Object[] params, String[] signature) throws MBeanException, ReflectionException
invoke in interface DynamicMBeanMBeanExceptionReflectionExceptionpublic final T getSource()
public final MBeanServer getServer()
public final ObjectName getName()
public final MBeanInfo getMBeanInfo()
getMBeanInfo in interface DynamicMBeanpublic final AttributeList getAttributes(String[] names)
getAttributes in interface DynamicMBeanpublic final AttributeList setAttributes(AttributeList attributes)
setAttributes in interface DynamicMBeanpublic final void setManagedResource(Object resource, String type) throws InstanceNotFoundException, InvalidTargetObjectTypeException, MBeanException
setManagedResource in interface ModelMBeanInstanceNotFoundExceptionInvalidTargetObjectTypeExceptionMBeanExceptionpublic final void setModelMBeanInfo(ModelMBeanInfo info) throws MBeanException
setModelMBeanInfo in interface ModelMBeanMBeanExceptionpublic void addAttributeChangeNotificationListener(NotificationListener listener, String name, Object handback)
addAttributeChangeNotificationListener in interface ModelMBeanNotificationBroadcasterpublic void removeAttributeChangeNotificationListener(NotificationListener listener, String name) throws ListenerNotFoundException
removeAttributeChangeNotificationListener in interface ModelMBeanNotificationBroadcasterListenerNotFoundExceptionpublic void sendAttributeChangeNotification(AttributeChangeNotification notification) throws MBeanException
sendAttributeChangeNotification in interface ModelMBeanNotificationBroadcasterMBeanExceptionpublic void sendAttributeChangeNotification(Attribute oldValue, Attribute newValue) throws MBeanException
sendAttributeChangeNotification in interface ModelMBeanNotificationBroadcasterMBeanExceptionpublic void sendNotification(Notification notification) throws MBeanException
sendNotification in interface ModelMBeanNotificationBroadcasterMBeanExceptionpublic void sendNotification(String message) throws MBeanException
sendNotification in interface ModelMBeanNotificationBroadcasterMBeanExceptionpublic void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback) throws IllegalArgumentException
addNotificationListener in interface NotificationBroadcasterIllegalArgumentExceptionpublic MBeanNotificationInfo[] getNotificationInfo()
getNotificationInfo in interface NotificationBroadcasterpublic void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
removeNotificationListener in interface NotificationBroadcasterListenerNotFoundExceptionpublic void load()
throws InstanceNotFoundException,
MBeanException,
RuntimeOperationsException
load in interface PersistentMBeanInstanceNotFoundExceptionMBeanExceptionRuntimeOperationsExceptionpublic void store()
throws InstanceNotFoundException,
MBeanException,
RuntimeOperationsException
store in interface PersistentMBeanInstanceNotFoundExceptionMBeanExceptionRuntimeOperationsExceptionpublic final ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
preRegister in interface MBeanRegistrationExceptionpublic final void postRegister(Boolean registrationDone)
postRegister in interface MBeanRegistrationpublic final void preDeregister()
throws Exception
preDeregister in interface MBeanRegistrationExceptionpublic final void postDeregister()
postDeregister in interface MBeanRegistrationprotected void setAttribute0(String attrName, Object attrValue) throws Exception
Exceptionprotected Object invoke0(String name, Object[] params, String[] signature) throws Exception
Exceptionprotected void addExtraAttributes(List<ModelMBeanAttributeInfo> attributes)
protected void addExtraOperations(List<ModelMBeanOperationInfo> operations)
protected PropertyEditor getPropertyEditor(Class<?> type, String attrName, Class<?> attrType)
Copyright © 2004–2019 Apache MINA Project. All rights reserved.