|
MySnmpCrawler API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--snmp.mbean.MBeanMeta
The MBeanMeta contains the reference to the MBean object. It also provides the generic behavior such as attribute locking when getting and setting the MBean attribute.
Field Summary | |
private java.util.HashMap |
attrLock
|
protected GenericMBean |
mbean
|
private static java.util.ArrayList |
mbeanMetaList
|
Fields inherited from interface snmp.mbean.SnmpMBean |
ACCESS_BY_ATTR_NAME, ACCESS_BY_OID |
Constructor Summary | |
protected |
MBeanMeta()
The default constructor. |
protected |
MBeanMeta(GenericMBean mbean)
Constructs the MBeanMeta object that is associated with GenericMBean object. |
Method Summary | |
MBeanAttribute |
get(java.lang.String identifier,
int accessType)
Gets the MBeanAttribute object that matches to the passed identifier in the MBean. |
protected abstract MBeanAttribute |
getAttrByName(java.lang.String attr)
Gets the MBeanAttribute object that matches to the attribute name in the MBean. |
protected abstract MBeanAttribute |
getAttrByOid(java.lang.String oid)
Gets the MBeanAttribute object that matches to the object identifier string in the MBean. |
java.lang.String |
getMBeanClassName()
Gets the class name of the MBean that associates with the MBeanMeta object. |
static MBeanMeta |
getMBeanMeta(java.lang.String mbeanName)
Gets the MBeanMeta object from the MBeanMeta list with the passed MBean name. |
javax.management.ObjectName |
getMBeanObjectName()
Gets the ObjectName of the MBean that associates with the MBeanMeta object. |
MBeanAttribute |
set(java.lang.String identifier,
int accessType,
MBeanAttribute attr)
Sets the MBeanAttribute object that matches to the passed identifier into the MBean. |
protected abstract MBeanAttribute |
setAttrByName(java.lang.String oid,
MBeanAttribute attr)
Sets the MBeanAttribute object that matches to the attribute name into the MBean. |
protected abstract MBeanAttribute |
setAttrByOid(java.lang.String oid,
MBeanAttribute attr)
Sets the MBeanAttribute object that matches to the object identifier string into the MBean. |
(package private) void |
setupMBeanMeta(GenericMBean mbean)
Setups the required objects for the MBeanMeta to work properly. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static java.util.ArrayList mbeanMetaList
protected GenericMBean mbean
private java.util.HashMap attrLock
Constructor Detail |
protected MBeanMeta() throws SnmpException
SnmpException
- Thrown when the instance of the
MBeanMeta cannot be constructed correctly.protected MBeanMeta(GenericMBean mbean) throws SnmpException
mbean
- The associated GenericMBean object.
SnmpException
- Thrown when the instance of the
MBeanMeta cannot be constructed correctly.Method Detail |
public MBeanAttribute get(java.lang.String identifier, int accessType) throws SnmpException
get
in interface SnmpMBean
identifier
- The identifier string.accessType
- Either ACCESS_BY_OID or ACCESS_BY_ATTR_NAME.
SnmpException
- Thrown when any error occurs.public MBeanAttribute set(java.lang.String identifier, int accessType, MBeanAttribute attr) throws SnmpException
set
in interface SnmpMBean
identifier
- The identifier string.accessType
- Either ACCESS_BY_OID or ACCESS_BY_ATTR_NAME.attr
- The MBeanAttribute object that contains the
data to be set into the MBean object.
SnmpException
- Thrown when any error occurs.public javax.management.ObjectName getMBeanObjectName() throws SnmpException
SnmpException
- Thrown when there is an error in getting
the ObjectName of the MBean.public java.lang.String getMBeanClassName()
void setupMBeanMeta(GenericMBean mbean) throws SnmpException
mbean
- The GenericMBean object associates with MBeanMeta.
SnmpException
- Thrown when any error occurs during the setup.public static MBeanMeta getMBeanMeta(java.lang.String mbeanName)
mbeanName
- The string represents the MBean name.
protected abstract MBeanAttribute getAttrByOid(java.lang.String oid) throws SnmpException
oid
- The string represents the object identifier.
SnmpException
- Thrown when any error occurs.protected abstract MBeanAttribute getAttrByName(java.lang.String attr) throws SnmpException
attr
- The string represents the attribute name.
SnmpException
- Thrown when any error occurs.protected abstract MBeanAttribute setAttrByOid(java.lang.String oid, MBeanAttribute attr) throws SnmpException
oid
- The string represents the object identifier.attr
- The MBeanAttribute object that contains the
data to be set into the MBean object.
SnmpException
- Thrown when any error occurs.protected abstract MBeanAttribute setAttrByName(java.lang.String oid, MBeanAttribute attr) throws SnmpException
attr
- The MBeanAttribute object that contains the
data to set into the MBean object.
SnmpException
- Thrown when any error occurs.
|
MySnmpCrawler API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |