|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectwt.jmx.core.StandardMBeanFix
wt.jmx.core.StandardMBean
wt.jmx.core.SelfAwareMBean
wt.jmx.core.mbeans.MBeanLoader
public final class MBeanLoader
This MBean provides XMLEncoder/XMLDecoder based
persistence to/from files for MBeans and other objects.
Supported API: true
Extendable: false
| Nested Class Summary | |
|---|---|
static class |
wt.jmx.core.mbeans.MBeanLoader.NamedMBean
Class and currently public methods must be public (and class must be static) for use by Bean persistence mechanism. |
static class |
wt.jmx.core.mbeans.MBeanLoader.ObjectNameAndAttrs
Class and currently public methods must be public (and class must be static) for use by Bean persistence mechanism. |
| Field Summary |
|---|
| Fields inherited from interface wt.jmx.core.mbeans.MBeanLoaderMBean |
|---|
LOAD_FINISHED_NOTIF_TYPE, LOAD_STARTED_NOTIF_TYPE, START_NOTIF_TYPE, STOP_NOTIF_TYPE, UNLOAD_FINISHED_NOTIF_TYPE, UNLOAD_STARTED_NOTIF_TYPE |
| Method Summary | ||
|---|---|---|
|
addAllInstancesOf(Class<T> objectClass,
Collection<T> instances)
Add all instances of 'objectClass' found in loader or its children to 'instances'. |
|
static MBeanLoader |
createAndRegisterMBeanLoader(String mbeanConfigFileRef)
Create, register, and generally start up a new MBeanLoader instance, setting MBeanConfigFileCheckInterval to a reasonable default value and BaseObjectName to null. |
|
static MBeanLoader |
createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval)
Create, register, and generally start up a new MBeanLoader instance, setting MBeanConfigFileCheckInterval to a reasonable default value. |
|
static MBeanLoader |
createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval,
ObjectName baseObjectName)
Create, register, and generally start up a new MBeanLoader instance Supported API: true |
|
static MBeanLoader |
createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval,
ObjectName baseObjectName,
boolean registerDestroyOnShutdownHook)
Create, register, and generally start up a new MBeanLoader instance and optionally register a shutdown hook to destroy the loader Supported API: true |
|
|
getInstanceOf(Class<T> objectClass)
Get first (by depth-first traversal ) instance of 'objectClass' found in loader or its children Supported API: true |
|
static MBeanLoader |
getLoader(SelfAwareMBean mbean)
Walk owner chain for 'mbean' and get most direct loader. |
|
static
|
getRelatedInstance(SelfAwareMBean mbeanContext,
Class<T> objectClass)
Get first instance of 'objectClass' found in the root loader that loaded 'mbeanContext'. |
|
static MBeanLoader |
getRootLoader(SelfAwareMBean mbean)
Walk owner chain for 'mbean' and get most top-most (root) loader. |
|
| Methods inherited from class wt.jmx.core.SelfAwareMBean |
|---|
deregister, destroy, getObjectName, getObjectNameOnPreRegister, getOwnerMBean, getSelfAwareMBean, init, isInited, isRegistered, isStarted, postDeregister, postRegister, preDeregister, preRegister, register, register, register, resetObjectName, setOwnerMBean, start, stop |
| Methods inherited from class wt.jmx.core.StandardMBean |
|---|
cacheMBeanInfo, cacheMBeanInfoInInstance, createMBeanInfo, emailThisMBean, getCachedInstanceMBeanInfo, getCachedMBeanInfo, getDescription, getDescription, getDescription, getDescription, getImpact, getMBeanInfo, getParameterName |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface wt.jmx.core.mbeans.MBeanLoaderMBean |
|---|
isStarted, start, stop |
| Methods inherited from interface wt.jmx.core.mbeans.SelfEmailingMBean |
|---|
emailThisMBean |
| Method Detail |
|---|
public static MBeanLoader createAndRegisterMBeanLoader(String mbeanConfigFileRef)
mbeanConfigFileRef - Reference (URL, file path, or resource path) of file from which MBeans will be loaded
public static MBeanLoader createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval)
mbeanConfigFileRef - Reference (URL, file path, or resource path) of file from which MBeans will be loadedmbeanConfigFileCheckInterval - Interval (in seconds) at which MBeanConfigFileRef will be checked for updates; disabled if non-positive
public static MBeanLoader createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval,
ObjectName baseObjectName)
mbeanConfigFileRef - Reference (URL, file path, or resource path) of file from which MBeans will be loadedmbeanConfigFileCheckInterval - Interval (in seconds) at which MBeanConfigFileRef will be checked for updates; disabled if non-positivebaseObjectName - Object name under which loaded (non-loader) objects will be located
public static MBeanLoader createAndRegisterMBeanLoader(String mbeanConfigFileRef,
int mbeanConfigFileCheckInterval,
ObjectName baseObjectName,
boolean registerDestroyOnShutdownHook)
mbeanConfigFileRef - Reference (URL, file path, or resource path) of file from which MBeans will be loadedmbeanConfigFileCheckInterval - Interval (in seconds) at which MBeanConfigFileRef will be checked for updates; disabled if non-positivebaseObjectName - Object name under which loaded (non-loader) objects will be locatedregisterDestroyOnShutdownHook - Whether shutdown hook to destroy this loader should be registered with the JVM runtimepublic static MBeanLoader getLoader(SelfAwareMBean mbean)
public static MBeanLoader getRootLoader(SelfAwareMBean mbean)
public <T> T getInstanceOf(Class<T> objectClass)
public <T> void addAllInstancesOf(Class<T> objectClass,
Collection<T> instances)
public static <T> T getRelatedInstance(SelfAwareMBean mbeanContext,
Class<T> objectClass)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||