Package org.apache.tomcat.util.modeler
Class ManagedBean
java.lang.Object
org.apache.tomcat.util.modeler.ManagedBean
- All Implemented Interfaces:
- Serializable
Internal configuration information for a managed bean (MBean) descriptor.
- Author:
- Craig R. McClanahan
- See Also:
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddAttribute(AttributeInfo attribute) Add a new attribute to the set of attributes for this MBean.voidaddNotification(NotificationInfo notification) Add a new notification to the set of notifications for this MBean.voidaddOperation(OperationInfo operation) Add a new operation to the set of operations for this MBean.createMBean(Object instance) Create and return aModelMBeanthat has been preconfigured with theModelMBeanInfoinformation for this managed bean, and is associated with the specified managed object instance.The fully qualified name of the Java class of the MBean described by this descriptor.getGroup()getName()getSetter(String aname, BaseModelMBean bean, Object resource) getType()voidsetClassName(String className) voidsetDescription(String description) voidvoidvoidvoidtoString()Return a string representation of this managed bean.
- 
Field Details- 
className
- 
description
- 
domain
- 
group
- 
name
- 
type
 
- 
- 
Constructor Details- 
ManagedBeanpublic ManagedBean()Constructor. Will add default attributes.
 
- 
- 
Method Details- 
getAttributes- Returns:
- the collection of attributes for this MBean.
 
- 
getClassNameThe fully qualified name of the Java class of the MBean described by this descriptor. If not specified, the standard JMX class (javax.management.modelmbean.RequiredModeLMBean) will be utilized.- Returns:
- the class name
 
- 
setClassName
- 
getDescription- Returns:
- the human-readable description of this MBean.
 
- 
setDescription
- 
getDomain- Returns:
- the (optional) ObjectNamedomain in which this MBean should be registered in the MBeanServer.
 
- 
setDomain
- 
getGroup- Returns:
- the (optional) group to which this MBean belongs.
 
- 
setGroup
- 
getName- Returns:
- the name of this managed bean, which must be unique among all MBeans managed by a particular MBeans server.
 
- 
setName
- 
getNotifications- Returns:
- the collection of notifications for this MBean.
 
- 
getOperations- Returns:
- the collection of operations for this MBean.
 
- 
getType- Returns:
- the fully qualified name of the Java class of the resource implementation class described by the managed bean described by this descriptor.
 
- 
setType
- 
addAttributeAdd a new attribute to the set of attributes for this MBean.- Parameters:
- attribute- The new attribute descriptor
 
- 
addNotificationAdd a new notification to the set of notifications for this MBean.- Parameters:
- notification- The new notification descriptor
 
- 
addOperationAdd a new operation to the set of operations for this MBean.- Parameters:
- operation- The new operation descriptor
 
- 
createMBeanpublic DynamicMBean createMBean(Object instance) throws InstanceNotFoundException, MBeanException, RuntimeOperationsException Create and return aModelMBeanthat has been preconfigured with theModelMBeanInfoinformation for this managed bean, and is associated with the specified managed object instance. The returnedModelMBeanwill NOT have been registered with ourMBeanServer.- Parameters:
- instance- Instanced of the managed object, or- nullfor no associated instance
- Returns:
- the MBean
- Throws:
- InstanceNotFoundException- if the managed resource object cannot be found
- MBeanException- if a problem occurs instantiating the- ModelMBeaninstance
- RuntimeOperationsException- if a JMX runtime error occurs
 
- 
toStringReturn a string representation of this managed bean.
- 
getSetterpublic Method getSetter(String aname, BaseModelMBean bean, Object resource) throws AttributeNotFoundException, ReflectionException 
- 
getInvokepublic Method getInvoke(String aname, Object[] params, String[] signature, BaseModelMBean bean, Object resource) throws MBeanException, ReflectionException - Throws:
- MBeanException
- ReflectionException
 
 
-