Interface InfoMBean
- All Superinterfaces:
SelfEmailingMBean
- All Known Subinterfaces:
NotificationHandlerMBean,SummaryMBean
- All Known Implementing Classes:
Info
Supported API: true
Extendable: true
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddCustomDelegateFactory(String factoryName, String factoryClass) Add custom delegate factory instance and associate it with the given name.voidaddInfoItem(ObjectName mbeanObjectName, String mbeanAttributeName, String displayName) Add item to end of list of those to be obtained
Supported API: truevoidchangeInfoItemDisplayName(int infoItemIdx, String displayName) Add item to end of list of those to be obtained
Supported API: trueDeprecated.Names and class of custom delegates
Supported API: trueString[]Names of custom delegate factories attached to this MBean
Supported API: trueStructured representation of items to be obtained; see InfoItemsAsStrings for alternate string representationString[]String representation of items to be obtained; format is: [index] mbeanObjectName mbeanAttributeName (displayName)
Supported API: trueString[]String preview representation of data currently selected by info items
Supported API: truevoidinsertInfoItem(int infoItemIdx, ObjectName mbeanObjectName, String mbeanAttributeName, String displayName) Insert item into list of those to be obtained
Supported API: truevoidremoveCustomDelegateFactory(String factoryName) Remove the custom delegate factory with the specified name
Supported API: truevoidremoveInfoItem(int infoItemIdx) Remove item from list of those to be obtained
Supported API: truevoidRemove all items from list of those to be obtained
Supported API: truevoidsetCustomDelegateFactoryClass(String customDelegateFactoryClassname) Deprecated.Methods inherited from interface wt.jmx.core.mbeans.SelfEmailingMBean
emailThisMBean
-
Method Details
-
getInfoItemsAsOpenData
Structured representation of items to be obtained; see InfoItemsAsStrings for alternate string representationAn array of CompositeData would make more sense here, but JMX consoles seem to fail to interpret this properly for display purposes when outside the context of a CompositeData or TabularData.
Supported API: true- Throws:
OpenDataException
-
getInfoItemsAsStrings
String[] getInfoItemsAsStrings()String representation of items to be obtained; format is: [index] mbeanObjectName mbeanAttributeName (displayName)
Supported API: true -
getInfoItemsPreview
String[] getInfoItemsPreview()String preview representation of data currently selected by info items
Supported API: true -
getCustomDelegateFactoryClass
Deprecated.THIS ATTRIBUTE IS OBSOLETE (since one can now have multiple custom delegate factories) and is retained purely for backwards compatibility.Returns name of custom delegate factory class.
This method is retained purely for backwards compatibility and should no longer be used. It may either obtain the class name of the first delegate factory by an undefined internal iterator ordering or simply throw a runtime exception when there are multiple custom delegate factories specified.
Supported API: true -
setCustomDelegateFactoryClass
@Deprecated void setCustomDelegateFactoryClass(String customDelegateFactoryClassname) throws ClassCastException, ClassNotFoundException, IllegalAccessException, InstantiationException Deprecated.THIS ATTRIBUTE IS OBSOLETE (since one can now have multiple custom delegate factories) and is retained purely for backwards compatibilitySets custom delegate factory class (removing all other factory instances) and using the class name as the factory name.
This method is retained purely for backwards compatibility and should no longer be used.
Supported API: true -
getCustomDelegateFactoryNames
String[] getCustomDelegateFactoryNames()Names of custom delegate factories attached to this MBean
Supported API: true -
getCustomDelegateFactoryData
Names and class of custom delegates
Supported API: true- Throws:
OpenDataException
-
addCustomDelegateFactory
@MBeanOperationImpact(1) void addCustomDelegateFactory(String factoryName, String factoryClass) throws ClassNotFoundException, InstantiationException, IllegalAccessException Add custom delegate factory instance and associate it with the given name.An attempt is made to find a constructor in the specified class taking a single String argument and call this constructor passing the specified name. If this fails, the no-arg constructor (which must be public) is used instead and an attempt is also made to call setName(String) on the instance. An attempt is also made to call setOwnerMBean(BaseObjectNamed) on the instance, passing it this MBean, so that any interested delegate factory can obtain this information.
If the factory is a
SelfAwareMBean, then the factory is registered as a child MBean of this MBean.The factory class must implement
InfoDelegateFactory. The factory class should also override equals() to return 'true' for logically equivalent instances.
Supported API: true- Parameters:
factoryName- Name to associate with custom delegate factory; will use factoryClass if this is nullfactoryClass- Name of custom delegate factory class; class must implement InfoDelegateFactory- Throws:
ClassNotFoundExceptionInstantiationExceptionIllegalAccessException
-
removeCustomDelegateFactory
Remove the custom delegate factory with the specified name
Supported API: true- Parameters:
factoryName- Name of custom delegate factory to remove
-
addInfoItem
@MBeanOperationImpact(0) void addInfoItem(ObjectName mbeanObjectName, String mbeanAttributeName, String displayName) Add item to end of list of those to be obtained
Supported API: true- Parameters:
mbeanObjectName- ObjectName (or ObjectNamePattern) of MBean(s) from which to obtain datambeanAttributeName- Name of attribute in 'mbeanObjectName' to obtain; can use .itemName-style suffixes to select CompositeData fieldsdisplayName- Display name to use for this item; used when UseShortFormat is false and FormatString is unspecified
-
insertInfoItem
@MBeanOperationImpact(1) void insertInfoItem(int infoItemIdx, ObjectName mbeanObjectName, String mbeanAttributeName, String displayName) Insert item into list of those to be obtained
Supported API: true- Parameters:
infoItemIdx- Index of item to insert in front ofmbeanObjectName- ObjectName (or ObjectNamePattern) of MBean(s) from which to obtain datambeanAttributeName- Name of attribute in 'mbeanObjectName' to obtain; can use .itemName-style suffixes to select CompositeData fieldsdisplayName- Display name to use for this item; used when UseShortFormat is false and FormatString is unspecified
-
changeInfoItemDisplayName
Add item to end of list of those to be obtained
Supported API: true- Parameters:
infoItemIdx- Index of item to changedisplayName- Display name to use for this item; used when UseShortFormat is false and FormatString is unspecified
-
removeInfoItem
Remove item from list of those to be obtained
Supported API: true- Parameters:
infoItemIdx- Index of item to remove
-
removeInfoItems
Remove all items from list of those to be obtained
Supported API: true
-