FileDocCategorySizeDatePackage
AMX.javaAPI DocGlassfish v2 API7975Fri May 04 22:30:30 BST 2007com.sun.appserv.management.base

AMX

public interface AMX implements NotificationEmitter, AMXMBeanLogging
Base interface implemented by all available interfaces part of the Appserver Application Programming Interface (AMX). An AMX is actually a dynamic client-side proxy to a server-side MBean. It provides a strongly typed and convenient interface for accessing the server-side MBeans.

Certain conventions are followed when an AMX provides access to other AMX instances; when a single item is returned, the return type is strongly-typed. When a Map or Set is returned, the values found in the Map or Set must be cast appropriately. The context should make it obvious what the appropriate cast is. It is always safe to cast to AMX, since this is base interface.

Additional information, such as {@link javax.management.MBeanInfo} for the target MBean, may be obtained via {@link Util#getExtra}

All AMX that emit Notifications place a Map within the userData field of a standard {@link javax.management.Notification} which may be obtained via {@link javax.management.Notification#getUserData}. Within the Map are zero or more items, which vary with the Notification type. Each Notification type, and data available within the Notification, is defined in its respective MBean or in an appropriate place.

see
Util#getExtra
see
com.sun.appserv.management.base.Extra
see
com.sun.appserv.management.base.Container
see
com.sun.appserv.management.base.StdAttributesAccess
see
com.sun.appserv.management.config.PropertiesAccess
see
com.sun.appserv.management.monitor.MonitoringStats
see
com.sun.appserv.management.j2ee.J2EEDomain

Fields Summary
public static final String
NOTIFICATION_PREFIX
The prefix for all Notification types issued by AMX.
public static final String
JMX_DOMAIN
The JMX domain in which all AMX MBeans are located.
public static final String
FULL_TYPE_DELIM
The delimiter between parts of a fully-qualified type as returned by {@link #getFullType}.
public static final String
GROUP_CONFIGURATION
Value from {@link #getGroup} indicating that the AMX is a configuration MBean.
public static final String
GROUP_MONITORING
Value from {@link #getGroup} indicating that the AMX represents a monitoring MBean.
public static final String
GROUP_UTILITY
Value from {@link #getGroup} indicating that the AMX is a utility MBean.
public static final String
GROUP_JSR77
Value from {@link #getGroup} indicating that the AMX is a JSR 77 MBean (J2EE Management) .
public static final String
GROUP_OTHER
Value from {@link #getGroup} indicating that the AMX is not one of the other types.
public static final String
J2EE_TYPE_KEY
The ObjectName property key denoting the type of the MBean.
public static final String
NAME_KEY
The ObjectName property key denoting the name of the MBean.
public static final String
NO_NAME
The name given to any MBean lacking a "real" name. Certain MBeans are singletons within their scope, and while they have a "name" field within their ObjectName (property {@link #NAME_KEY}), they have no meaningful name.
public static final String
NULL_NAME
The name used when a FullType part refers to a non-existent parent eg a standalone ejb or web module that has a null J2EEApplication.
Constructors Summary
Methods Summary
public ContainergetContainer()
Get the AMX which logically contains this one. All AMX have a Container except for DomainRoot.

return
the parent proxy for this one, possibly null.
see
AMXAttributes#ATTR_CONTAINER_OBJECT_NAME

public com.sun.appserv.management.DomainRootgetDomainRoot()
Get the DomainRoot.

return
the Domain representing the Appserver Domain to which this belongs

public java.lang.StringgetFullType()
Format:
[[[part].]*]j2eeType
Example for j2eeType=Servlet:
type=J2EEServer.J2EEApplication.WebModule.Servlet

see
AMXAttributes#ATTR_FULL_TYPE

public java.lang.StringgetGroup()
Possible values include:
  • {@link #GROUP_CONFIGURATION}
  • {@link #GROUP_MONITORING}
  • {@link #GROUP_UTILITY}
  • {@link #GROUP_JSR77}
  • {@link #GROUP_OTHER}

return
the group to which this AMX belongs.
see
AMXAttributes#ATTR_GROUP

public java.lang.StringgetJ2EEType()
Get the j2eeType of this item. Same as the value of the 'j2eeType' property within the ObjectName. The ObjectNames of all AMX contain a property whose key is "j2eeType" ({@link #J2EE_TYPE_KEY}) and whose value is specific to the sub-interface the item represents. Equivalent to the J2EE_TYPE field found in each AMX sub-interface.

return
String which is the j2eeType
see
XTypes
see
com.sun.appserv.management.j2ee.J2EETypes

public java.lang.StringgetName()
Get the name of this item. Same as the value of the 'name' property within the ObjectName.

return
the "name" property value as found inside the ObjectName
see
#NAME_KEY

public booleanisDAS()

return
true if this MBean runs natively in DAS, or false if it's a proxy to an MBean outside the DAS.