Save This Page
Home » jboss-5.0.0.CR1-src » org.jboss.mx » server » registry » [javadoc | source]
org.jboss.mx.server.registry
public interface: MBeanRegistry [javadoc | source]

All Known Implementing Classes:
    BasicMBeanRegistry

Implementations of this interface can be plugged into the MBeanServer, to control the registration and deregistration of MBeans.

The registry can expose itself for management under the object name defined the name defined in ServerConstants When this is the case, the MBeanServer will perform the register/unregister operations dynamically.

Method from org.jboss.mx.server.registry.MBeanRegistry Summary:
contains,   findEntries,   get,   getDefaultDomain,   getDomains,   getObjectInstance,   getSize,   getValue,   registerMBean,   releaseRegistry,   unregisterMBean
Method from org.jboss.mx.server.registry.MBeanRegistry Detail:
 public boolean contains(ObjectName name)
    Test whether an object name is registered.

    This method is invoked by the MBeanServer for isRegistered().

    The object name passed maybe unqualified.

 public List findEntries(ObjectName pattern)
    Return a List of MBeanEntry objects with ObjectNames that match the specified pattern.

    This method is invoked by the MBeanServer for queryMBeans() and queryNames().

 public MBeanEntry get(ObjectName name) throws InstanceNotFoundException
    Retrieve the registration for an object name.

    This method is invoked by the MBeanServer for methods passing an ObjectName that are not covered in other methods.

    The object name passed maybe unqualified.

 public String getDefaultDomain()
    Retrieve the default domain for this registry.

 public String[] getDomains()
    Retrieve the domains for this registry.

 public ObjectInstance getObjectInstance(ObjectName name) throws InstanceNotFoundException
    Retrieve the object instance for an object name.
 public int getSize()
    Retrieve the number of mbeans registered.

    This method is invoked by the MBeanServer for getMBeanCount().

 public Object getValue(ObjectName name,
    String key) throws InstanceNotFoundException
    Retrieve a value from the registration.
 public ObjectInstance registerMBean(Object object,
    ObjectName name,
    Map valueMap) throws MBeanRegistrationException, InstanceAlreadyExistsException, NotCompliantMBeanException
    Register an mbean.

    This method is invoked by the MBeanServer for createMBean() and registerMBean().

    The object name passed maybe unqualified.

    The map is a user definable string to value object map for holding information against a registered object. This map may contain metadata related to the registration, such as registration date/time, classloader references, etc.

    Pass JMI_DOMAIN in both the key and values of the values map to get access to the reserved domain. It is removed from the map during registration to save memory.

    Pass CLASSLOADER in the values map to set the context classloader

    Other values are user definable and can be retrieved using the getValue(ObjectName,String) method.

 public  void releaseRegistry()
    Invoked before the MBean server instance is released. Implementing this method lets the registry to process any clean up before the MBean server is shut down.
 public  void unregisterMBean(ObjectName name) throws InstanceNotFoundException, MBeanRegistrationException
    Unregister an mbean.

    This method is invoked by the MBeanServer for unregisterMBean().

    The object name passed maybe unqualified.

    MBeans in JMImplementation cannot be unregistered