|
MySnmpCrawler API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--snmp.lib.ServiceLocator
This class provides the service to get the objects of major components. The service includes: getSnmpAgent, getMBeanServer, getMibDatabase, and getSnmpMBean that retrieves the SnmpMBean object matching to the OID group name.
Field Summary | |
private AccessControl |
accessCtrl
|
private javax.management.MBeanServer |
mbeanServer
|
private MibDatabase |
mibdb
|
private static ServiceLocator |
singleton
|
private SnmpAgent |
snmpAgent
|
Constructor Summary | |
private |
ServiceLocator(SnmpAgent agent)
Constructs the ServiceLocator object with the SnmpAgent.. |
Method Summary | |
static ServiceLocator |
getInstance()
Gets the singleton object of the ServiceLocator. |
javax.management.MBeanServer |
getMBeanServer()
Gets the MBeanServer object. |
MibDatabase |
getMibDatabase()
Gets the MibDatabase object. |
SnmpAgent |
getSnmpAgent()
Gets the SnmpAgent object. |
SnmpMBean |
getSnmpMBean(java.lang.String oidGroupName)
Gets the SnmpMBean object matching to the OID group name. |
private void |
init()
Invoked to load the objects of major components. |
static ServiceLocator |
loadService(SnmpAgent agent)
Invoked to load the service with the SnmpAgent object when the system starts. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static ServiceLocator singleton
private SnmpAgent snmpAgent
private javax.management.MBeanServer mbeanServer
private MibDatabase mibdb
private AccessControl accessCtrl
Constructor Detail |
private ServiceLocator(SnmpAgent agent) throws SnmpException
SnmpException
- thrown if any error occurs during the object
instantiation.Method Detail |
private void init() throws SnmpException
SnmpException
- thrown if any error occurs during objects
initialization.public SnmpAgent getSnmpAgent()
public javax.management.MBeanServer getMBeanServer()
public MibDatabase getMibDatabase()
public SnmpMBean getSnmpMBean(java.lang.String oidGroupName) throws SnmpException
oidGroupName
- The OID group name.
SnmpException
public static ServiceLocator loadService(SnmpAgent agent) throws SnmpException
SnmpException
- thrown if any error occurs during the object
instantiation.public static ServiceLocator getInstance() throws SnmpException
SnmpException
- thrown if any error occurs during the object
instantiation.
|
MySnmpCrawler API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |