com.ibm.websphere.management

Class RuntimeCollaborator

  1. java.lang.Object
  2. extended bycom.ibm.websphere.management.RuntimeCollaborator

  1. public abstract class RuntimeCollaborator
  2. extends java.lang.Object
A class to setup the managed resource object of a ModelMBean. The ModelMBean associated with this class is automatically set to be the managed resource, so classes do not have to call setManagedResource(). This class also emits notifications if an attribute is changed to all listeners.

Field Summary

Modifier and Type Field and Description
  1. protected
  2. javax.management.modelmbean.ModelMBean
modelMBean

Constructor Summary

Constructor and Description
RuntimeCollaborator()

Method Summary

Modifier and Type Method and Description
  1. void
bindMBean(javax.management.modelmbean.ModelMBeanInfo info,javax.management.modelmbean.ModelMBean bean)
Bind the ModelMBeanInfo Object with specific runtime object.
  1. javax.management.ObjectName
getObjectName()
  1. void
mbeanActivated()
Called when the MBean for which this is the managed resource is activated.
  1. void
sendNotification(javax.management.Notification ntfyObj)
Send the given notification through the ModelMBean.
  1. void
sendNotification(java.lang.String ntfyText)
Send a notification with the given text through the ModelMBean.
  1. void
setObjectName(javax.management.ObjectName name)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

modelMBean

  1. protected javax.management.modelmbean.ModelMBean modelMBean

Constructor Detail

RuntimeCollaborator

  1. public RuntimeCollaborator()

Method Detail

bindMBean

  1. public void bindMBean(javax.management.modelmbean.ModelMBeanInfo info,
  2. javax.management.modelmbean.ModelMBean bean)
  3. throws java.lang.Exception
Bind the ModelMBeanInfo Object with specific runtime object. More specifically, this method sets the TargetObject and TargetType for attributes and operations.

IMPORTANT: Subclasses which modify the ModelMBeanInfo should not use the info parameter passed on this method; instead they should get and set the ModelMBeanInfo on the ModelMBean itself. For example:

    ModelMBeanInfo mbeanInfo = (ModelMBeanInfo) bean.getMBeanInfo();
    ... modify the ModelMBeanInfo ...
    bean.setModelMBeanInfo(mbeanInfo);
 

Parameters:
info - - the ModelMBeanInfo instance that the runtime object is to be bound to; this should only be used for read-access of the ModelMBeanInfo
bean - - the ModelMBean instance that the runtime object is to be bound to.
Throws:
java.lang.Exception

sendNotification

  1. public void sendNotification(javax.management.Notification ntfyObj)
  2. throws javax.management.MBeanException
  3. javax.management.RuntimeOperationsException
Send the given notification through the ModelMBean.
Throws:
javax.management.MBeanException
javax.management.RuntimeOperationsException
See Also:
ModelMBeanNotificationBroadcaster.sendNotification(Notification)

sendNotification

  1. public void sendNotification(java.lang.String ntfyText)
  2. throws javax.management.MBeanException
  3. javax.management.RuntimeOperationsException
Send a notification with the given text through the ModelMBean.
Throws:
javax.management.MBeanException
javax.management.RuntimeOperationsException
See Also:
ModelMBeanNotificationBroadcaster.sendNotification(String)

getObjectName

  1. public javax.management.ObjectName getObjectName( )

setObjectName

  1. public void setObjectName(javax.management.ObjectName name)

mbeanActivated

  1. public void mbeanActivated()
Called when the MBean for which this is the managed resource is activated. This should be overridden by implementations that need to perform some action after the MBean is activated.