Methods Summary |
---|
public java.lang.Object | getAttribute(java.lang.String str)Get value of specified attribute. As there are no attributes exposed by
this object, the method always throws AttributeNotFoundException.
String msg = localStrings.getString( "admin.monitor.unknown_attribute", str );
throw new AttributeNotFoundException( msg );
|
public com.sun.enterprise.admin.monitor.types.MonitoredAttributeType | getAttributeType(java.lang.String str)Get type of specified monitored attribute. As there are no attributes
exposed by this object, the method always throws
UnsupportedOperationException.
String msg = localStrings.getString( "admin.monitor.unsupported_getattributetype" );
throw new UnsupportedOperationException( msg );
|
public javax.management.AttributeList | getAttributes(java.lang.String[] str)Get the values of several attributes of the monitoring MBean. As there
are no attributes exposed by this MBean, the method always returns a
empty AttributeList.
return new AttributeList();
|
public javax.management.MBeanInfo | getMBeanInfo()Provides the exposed attributes and actions of the monitoring MBean using
an MBeanInfo object.
if (genericMBeanInfo == null) {
genericMBeanInfo = createMBeanInfo(new HashMap());
}
return genericMBeanInfo;
|
private java.util.HashMap | getMonitoredObjectTypeMap(MonitoredObjectType[] typeList)Get a map of type and MonitoredObjectType instances from the array of
MonitoredObjectType instances.
HashMap map = new HashMap();
int size = (typeList != null) ? typeList.length : 0;
for (int i = 0; i < size; i++) {
map.put(typeList[i].getTypeName(), typeList[i]);
}
return map;
|
public java.util.Map | getMonitoringMetaData()Get a map of monitored attribute names and their types. The keys in
the map are names of the attribute and the values are their types. The
type value are instances of class
com.iplanet.ias.monitor.type.MonitoredAttributeType (or its sub-classes).
As no attributes are exposed by this MBean, it always returns a empty
map.
return new HashMap();
|
public static com.sun.enterprise.admin.monitor.GenericMonitorMBean | getRoot()Get root monitoring MBean. The root MBean is initialized when the
server starts up and is available thereafter.
if (root == null) {
root = new GenericMonitorMBean();
root.setNodeName(ObjectNames.kMonitoringRootClass);
root.setNodeType(ObjectNames.kMonitoringRootClass);
String instName = AdminService.getAdminService().getInstanceName();
ObjectName objName = ObjectNames.getRootMonitorMBeanName(instName);
objectNameMap.put(objName, root);
root.setObjectName(objName);
}
return root;
|
private void | startMonitoring(java.util.HashMap typeMap)Start monitoring on all child mbeans whose type is included in the
specified typeMap.
Iterator iter = childList.iterator();
while (iter.hasNext()) {
BaseMonitorMBean mBean = (BaseMonitorMBean)iter.next();
if (typeMap.containsKey(mBean.getNodeType())) {
if (mBean.getClass() == GenericMonitorMBean.class) {
((GenericMonitorMBean)mBean).startMonitoring(typeMap);
} else {
mBean.startMonitoring();
}
}
}
|
public void | startMonitoring()Start monitoring on the resource represented by this MBean. This method
starts monitoring on all child monitoring MBeans of this MBean by calling
startMonitoring on them one after another.
Iterator iter = childList.iterator();
while (iter.hasNext()) {
BaseMonitorMBean mBean = (BaseMonitorMBean)iter.next();
mBean.startMonitoring();
}
|
public void | startMonitoring(MonitoredObjectType[] typeList)Start monitoring on the resource represented by this MBean, if the type
of this MBean is included in the type list. The method will also result
in call to startMonitoring() of all child MBeans of the type included in
the type list.
HashMap typeMap = getMonitoredObjectTypeMap(typeList);
startMonitoring(typeMap);
|
public void | stopMonitoring(MonitoredObjectType[] typeList)Stop monitoring on the resource represented by this MBean, if the type
of this MBean is included in the type list. The method will also result
in call to startMonitoring() of all child MBeans of the type included in
the type list.
HashMap typeMap = getMonitoredObjectTypeMap(typeList);
stopMonitoring(typeMap);
|
private void | stopMonitoring(java.util.HashMap typeMap)Stop monitoring on all child mbeans whose type is included in the
specified typeMap.
Iterator iter = childList.iterator();
while (iter.hasNext()) {
BaseMonitorMBean mBean = (BaseMonitorMBean)iter.next();
if (typeMap.containsKey(mBean.getNodeType())) {
if (mBean.getClass() == GenericMonitorMBean.class) {
((GenericMonitorMBean)mBean).stopMonitoring(typeMap);
} else {
mBean.stopMonitoring();
}
}
}
|
public void | stopMonitoring()Stop monitoring on the resource represented by this MBean. This method
stops monitoring on all child monitoring MBeans of this MBean by calling
stopMonitoring on them one after another.
Iterator iter = childList.iterator();
while (iter.hasNext()) {
BaseMonitorMBean mBean = (BaseMonitorMBean)iter.next();
mBean.stopMonitoring();
}
|