Methods Summary |
---|
public static java.lang.String | getApplicationName(javax.management.ObjectName objectName)
String app = null;
app = objectName.getKeyProperty(ObjectNames.kApplicationNameKeyName);
return ( app );
|
public static java.lang.String | getClassId(javax.management.ObjectName objectName)
String classId = objectName.getKeyProperty(ObjectNames.kClassIdKeyName);
return ( classId );
|
public static java.lang.String | getGroupId(javax.management.ObjectName objectName)
String moduleType = null;
moduleType = objectName.getKeyProperty(ObjectNames.kGroupIdKeyName);
return ( moduleType );
|
public static java.lang.String | getHttpListenerId(javax.management.ObjectName objectName)
String listenerId = null;
listenerId = objectName.getKeyProperty(ObjectNames.kHTTPListenerIdKeyName);
return ( listenerId );
|
public static javax.management.ObjectName[] | getInstanceRelatedMBeans(javax.management.MBeanServer mbs, java.lang.String instanceName)Returns array of config MBeans created for given server instance
final ObjectName pattern = ObjectNames.getAllObjectNamesPattern(); //aka "ias:*"
final Set names = mbs.queryMBeans(pattern, null);
/* gets all the mbeans in the "ias" domain */
final Iterator iter = names.iterator();
final ArrayList arr = new ArrayList();
while(iter.hasNext()) {
final ObjectInstance objectInstance = (ObjectInstance) iter.next();
final ObjectName objectName = objectInstance.getObjectName();
final String name = ObjectNameHelper.getServerInstanceName(objectName);
if(instanceName.equals(name)) {
arr.add(objectName);
}
}
return (ObjectName [])arr.toArray(new ObjectName[arr.size()]);
|
public static java.lang.String | getModuleType(javax.management.ObjectName objectName)
String moduleType = null;
moduleType = objectName.getKeyProperty(ObjectNames.kModuleTypeKeyName);
return ( moduleType );
|
public static java.lang.String | getName(javax.management.ObjectName objectName)Returns the name of the MBean denoted by this ObjectName. Name is the
value of property with name "name" in key properties.
String name = objectName.getKeyProperty(ObjectNames.kNameKeyName);
return ( name );
|
public static java.lang.String | getServerId(javax.management.ObjectName objectName)
String serverId = objectName.getKeyProperty(ObjectNames.kServerIdKeyName);
return ( serverId );
|
public static java.lang.String | getServerInstanceName(javax.management.ObjectName objectName)
String instanceName = null;
if (getType(objectName) != null) {
if (getType(objectName).equals(ObjectNames.kServerInstance))
{
instanceName = getName(objectName);
}
else
{
instanceName = objectName.getKeyProperty(ObjectNames.kServerInstanceKeyName);
}
}
return ( instanceName );
|
public static java.lang.String | getType(javax.management.ObjectName objectName)A static method that returns type of the MBean as indicated in
com.sun.enterprise.admin.common.ObjectNames class. The given ObjectName
may not be null. Returns null, if the ObjectName does not contain
a property with name "type" in its property name value set.
String type = objectName.getKeyProperty(ObjectNames.kTypeKeyName);
//type has to one of the declared ones and hence this should be asserted.
return ( type );
|
public static java.lang.String | getVirtualServerClassId(javax.management.ObjectName objectName)
String classId = objectName.getKeyProperty(
ObjectNames.kVirtualServerClassIdKeyName);
return ( classId );
|
public static java.lang.String | getVirtualServerId(javax.management.ObjectName objectName)
String virtualServerId = objectName.getKeyProperty(
ObjectNames.kVirtualServerIdKeyName);
return ( virtualServerId );
|
public static boolean | isMonitorMBean(javax.management.ObjectName objectName)Returns true if this MBean is of type monitor.
Useful to decide whether the persistent storage check should
be performed.
boolean isMonitor = false;
String monitorKeyValue = null;
monitorKeyValue = objectName.getKeyProperty(
ObjectNames.kTypeKeyName);
if (monitorKeyValue != null)
{
isMonitor = monitorKeyValue.
equals(ObjectNames.kMonitoringType);
}
return ( isMonitor );
|