Package org.glassfish.gmbal.impl
Class MBeanImpl
java.lang.Object
javax.management.NotificationBroadcasterSupport
org.glassfish.gmbal.impl.MBeanImpl
- All Implemented Interfaces:
DynamicMBean,NotificationBroadcaster,NotificationEmitter,GmbalMBean,FacetAccessor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid<T> voidaddFacet(T obj) Add a facet to the object.children()boolean<T> TAccess the Facet of Class T from the object.facets()Return a list of all facets on this object.Fetch the value of the field from whichever facet contains the field.getAttribute(String attribute) getAttributes(String[] attributes) getParentPathPart(String rootParentPrefix) inthashCode()Invoke method on the appropriate facet of this object, that is, on the facet corresponding to method.getDeclaringClass.name()voidvoidobjectName(ObjectName oname) parent()voidvoidregister()voidremoveChild(MBeanImpl child) voidremoveFacet(Class<?> cls) Remove the facet (if any) of the given type.voidvoidsetAttribute(Attribute attribute) setAttributes(AttributeList attributes) skeleton()booleanvoidsuspended(boolean flag) target()toString()type()voidMethods inherited from class javax.management.NotificationBroadcasterSupport
addNotificationListener, handleNotification, removeNotificationListener, removeNotificationListener, sendNotificationMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, removeNotificationListenerMethods inherited from interface javax.management.NotificationEmitter
removeNotificationListener
-
Constructor Details
-
MBeanImpl
-
-
Method Details
-
equals
-
hashCode
public int hashCode() -
toString
-
skeleton
-
type
-
target
-
name
-
name
-
objectName
-
objectName
-
parent
-
parent
-
children
-
addChild
-
removeChild
-
getParentPathPart
-
suspended
public boolean suspended() -
suspended
public void suspended(boolean flag) -
register
public void register() throws InstanceAlreadyExistsException, MBeanRegistrationException, NotCompliantMBeanException -
unregister
-
getAttribute
public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException - Specified by:
getAttributein interfaceDynamicMBean- Throws:
AttributeNotFoundExceptionMBeanExceptionReflectionException
-
setAttribute
public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException - Specified by:
setAttributein interfaceDynamicMBean- Throws:
AttributeNotFoundExceptionInvalidAttributeValueExceptionMBeanExceptionReflectionException
-
getAttributes
- Specified by:
getAttributesin interfaceDynamicMBean
-
setAttributes
- Specified by:
setAttributesin interfaceDynamicMBean
-
invoke
public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException - Specified by:
invokein interfaceDynamicMBean- Throws:
MBeanExceptionReflectionException
-
getNotificationInfo
- Specified by:
getNotificationInfoin interfaceNotificationBroadcaster- Overrides:
getNotificationInfoin classNotificationBroadcasterSupport
-
getMBeanInfo
- Specified by:
getMBeanInfoin interfaceDynamicMBean
-
facet
Description copied from interface:FacetAccessorAccess the Facet of Class T from the object.- Specified by:
facetin interfaceFacetAccessor- Type Parameters:
T- The Type (as a Class) of the Facet.- Parameters:
cls- The class of the facet.- Returns:
- Instance of cls for this facet. Null if no such facet is available.
-
addFacet
public <T> void addFacet(T obj) Description copied from interface:FacetAccessorAdd a facet to the object. The type T must not already be available as a facet.- Specified by:
addFacetin interfaceFacetAccessor
-
removeFacet
Description copied from interface:FacetAccessorRemove the facet (if any) of the given type.- Specified by:
removeFacetin interfaceFacetAccessor- Parameters:
cls- The class of the facet to remove.
-
invoke
Description copied from interface:FacetAccessorInvoke method on the appropriate facet of this object, that is, on the facet corresponding to method.getDeclaringClass.- Specified by:
invokein interfaceFacetAccessor- Parameters:
method- The method to invoke.args- Arguments to the method.- Returns:
- restult of the invoke call.
-
facets
Description copied from interface:FacetAccessorReturn a list of all facets on this object.- Specified by:
facetsin interfaceFacetAccessor- Returns:
- Collection of all facets.
-
get
Description copied from interface:FacetAccessorFetch the value of the field from whichever facet contains the field. Read-only because that's all that the intended application needs.- Specified by:
getin interfaceFacetAccessor- Parameters:
field- The field to access- Returns:
- The value of the field
-
set
- Specified by:
setin interfaceFacetAccessor
-