|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.adventnet.snmp.mibs.MibModule
This class represents a MIB module, and enables operations on MIB modules loaded from MIB files.
Typically one MIB module is specified in an MIB file. This class instance for an MIB module is obtained by loading an MIB through the MibOperations object.
In most cases you will not use the methods in this class, but rather the functions in MibOperations which apply across all loaded MIBs. Use this class to restrict your operation to a specific MIB module. This is not advisable always. Infact, some of the methods will use mibOps to get the appropriate values.
Method Summary | |
MibNode |
getAgentCapabilities()
Deprecated. since 4.0 . Instead you can use the method getDefinedAgentCapabilities |
AgentCapabilities |
getAgentCapabilities(java.lang.String acName)
Returns the AgentCapabilities object present in this module. |
java.util.Enumeration |
getDefinedAgentCapabilities()
Returns the Enumeration of AgentCapabilities present in this module. |
java.util.Enumeration |
getDefinedModuleCompliances()
Returns the ModuleCompliances present in this module. |
java.util.Enumeration |
getDefinedNodes()
Gets all the nodes defined in this module using this method. |
java.util.Enumeration |
getDefinedNotificationGroups()
Gets all the NotificationGroup objects defined in this module. |
java.util.Enumeration |
getDefinedNotifications()
Gets all the NOTIFICATION-TYPE objects defined in this module. |
java.util.Enumeration |
getDefinedNotificationTypes()
Gets all the NotificationType objects defined in this module. |
java.util.Enumeration |
getDefinedObjectGroups()
Gets all the ObjectGroup objects defined in this module. |
java.util.Enumeration |
getDefinedTCs()
Gets all the TEXTUAL-CONVENTIONS defined in this module. |
java.util.Enumeration |
getDefinedTraps()
Gets all the TRAP-TYPE objects defined in this MIB module. |
java.lang.String |
getFilename()
Deprecated. since 2.1 . Instead you can use the method getFileName() |
java.lang.String |
getFileName()
Gets the filename of this module. |
java.lang.String |
getImportedModules()
Gets the names of the modules imported by this module. |
java.util.Hashtable |
getImports()
Gets the imported elements in the MIB. |
LeafSyntax |
getLeafSyntax(SnmpOID oid)
Gets the syntax of the node corresponding to this oid. |
ModuleIdentity |
getMibModuleIdentity()
Gets the ModuleIdentity object for the given name. |
MibNode |
getMibNode(int[] oid)
Gets the MibNode corresponding to the int array of OID. |
MibNode |
getMibNode(SnmpOID oid)
Gets the MibNode corresponding to the SnmpOID argument |
MibNode |
getMibNode(java.lang.String oid)
Gets the MibNode corresponding to the String OID argument. |
MibNode |
getMibNode(java.util.Vector oid)
Gets the MibNode per the Vector of Strings OID argument. |
MibNode |
getMibNodeByName(java.lang.String nodeLabel)
Gives the MibNode corresponding to the specified nodeLabel |
MibNode |
getMibNotification(java.lang.String name)
Gets the NOTIFICATION-TYPE object corresponding to the given name. |
MibTC |
getMibTC(java.lang.String name)
Gets the TEXTUAL-CONVENTION corresponding to the given name. |
MibTrap |
getMibTrap(java.lang.String name)
Used to get the MibTrap object by giving the trap name. |
boolean |
getMibVersion()
Used to know,whether the loaded MIB module is a SMIv1 MIB (Structure of Management Information) or SMIv2 MIB. |
ModuleCompliance |
getModuleCompliance(java.lang.String mcName)
Returns the ModuleComplience object corresponding to the given name. |
MibNode |
getModuleIdentity()
Gives the MODULE-IDENTITY node defined in the MIB. |
java.lang.String |
getName()
Gets the name of this MIB module. |
MibNode |
getNearestNode(int[] oid)
Gets the Nearest MibNode corresponding to the int array of OID. |
NotificationGroup |
getNotificationGroup(java.lang.String name)
Gets the NotificationGroup object for the given name. |
NotificationType |
getNotificationType(java.lang.String name)
Gets the NotificationType object for the given name. |
ObjectGroup |
getObjectGroup(java.lang.String name)
Gets the ObjectGroup object for the given name. |
MibNode |
getRootNode()
Gets a reference to the root node in this MIB module. |
java.util.Vector |
getRootNodes()
Returns a collection of root nodes. |
SnmpOID |
getSnmpOID(java.lang.String s)
Creates an SnmpOID instance from the specified string and information from this Module. |
java.lang.String |
toString()
Returns the name of this MibModule. |
java.lang.String |
translateToNames(java.lang.String oid)
Used for translating numbered OID String to named OID String. |
java.lang.String |
translateToNumbers(java.lang.String oid)
Used for translating named OID String to numbered OID String. |
Method Detail |
public boolean getMibVersion()
public java.lang.String getName()
public java.lang.String toString()
getName()
public MibNode getRootNode()
getRootNodes()
public java.util.Vector getRootNodes()
getRootNode()
public java.util.Enumeration getDefinedTraps()
getMibTrap(java.lang.String)
public MibTrap getMibTrap(java.lang.String name)
name
- the name of the trapMibOperations.getMibTrap(com.adventnet.snmp.snmp2.SnmpOID, int, int)
public java.util.Enumeration getDefinedNotifications()
getMibNotification(java.lang.String)
public MibNode getMibNotification(java.lang.String name)
name
- label of the node whose macro-type is NOTIFICATION-TYPEpublic java.util.Enumeration getDefinedNodes()
public java.lang.String getFileName()
public java.lang.String getFilename()
getFileName()
public MibNode getModuleIdentity()
public MibNode getAgentCapabilities()
public java.util.Enumeration getDefinedAgentCapabilities()
public AgentCapabilities getAgentCapabilities(java.lang.String acName)
public java.util.Enumeration getDefinedModuleCompliances()
public ModuleCompliance getModuleCompliance(java.lang.String mcName)
public java.lang.String getImportedModules()
getImports()
public java.lang.String translateToNames(java.lang.String oid)
oid
- numbered OID string(e.g. .1.3.6.)public java.lang.String translateToNumbers(java.lang.String oid)
oid
- OID String( e.g. .iso.org.dod)public MibNode getMibNodeByName(java.lang.String nodeLabel)
nodeLabel
- the name of the nodepublic MibNode getMibNode(java.lang.String oid)
oid
- String OIDpublic LeafSyntax getLeafSyntax(SnmpOID oid)
oid
- the SnmpOID instance of the nodepublic MibNode getMibNode(SnmpOID oid)
oid
- an instance of SnmpOIDpublic MibNode getMibNode(java.util.Vector oid)
oid
- Vector of Strings OIDpublic MibNode getMibNode(int[] oid)
oid
- Integer array of the OIDpublic MibNode getNearestNode(int[] oid)
oid
- Integer array of the OIDpublic SnmpOID getSnmpOID(java.lang.String s)
s
- String OID(e.g. .1.3.6 or .iso.org.dod)public java.util.Enumeration getDefinedTCs()
getMibTC(java.lang.String)
public MibTC getMibTC(java.lang.String name)
name
- the label of the TEXTUAL-CONVENTIONpublic java.util.Hashtable getImports()
public java.util.Enumeration getDefinedNotificationTypes()
getNotificationType(java.lang.String)
,
getDefinedNotifications()
public NotificationType getNotificationType(java.lang.String name)
name
- label of the node whose macro-type is NOTIFICATION-TYPEgetMibNotification(java.lang.String)
public java.util.Enumeration getDefinedNotificationGroups()
getNotificationGroup(java.lang.String)
public NotificationGroup getNotificationGroup(java.lang.String name)
name
- label of the node whose macro-type is NOTIFICATION-GROUPpublic java.util.Enumeration getDefinedObjectGroups()
getObjectGroup(java.lang.String)
public ObjectGroup getObjectGroup(java.lang.String name)
name
- label of the node whose macro-type is OBJECT-GROUPpublic ModuleIdentity getMibModuleIdentity()
name
- label of the node whose macro-type is MODULE-IDENTITY
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |