com.adventnet.snmp.mibs
Class JdbcMibTrap

java.lang.Object
  |
  +--com.adventnet.snmp.mibs.MibTrap
        |
        +--com.adventnet.snmp.mibs.JdbcMibTrap

class JdbcMibTrap
extends MibTrap
implements java.io.Serializable

See Also:
Serialized Form

Field Summary
(package private)  java.lang.String description
           
(package private)  java.lang.String enterprise
           
(package private)  JdbcMibOperations jMibOps
           
(package private)  java.lang.String moduleName
           
(package private)  java.lang.String name
           
(package private)  java.lang.String queryString
           
(package private)  java.lang.String reference
           
(package private)  java.sql.ResultSet rs
           
(package private)  java.lang.String tableName
           
(package private)  int value
           
(package private)  java.util.Vector variables
           
 
Fields inherited from class com.adventnet.snmp.mibs.MibTrap
commentObj, description, enterprise, enterpriseString, module, moduleName, name, reference, value, variables
 
Constructor Summary
  JdbcMibTrap()
           
(package private) JdbcMibTrap(java.lang.String modulename, java.lang.String Name, JdbcMibOperations jdbcMibOps)
           
 
Method Summary
 java.lang.String getDescription()
          Gets the value of the DESCRIPTION clause.
 SnmpOID getEnterprise()
          Gets the enterprise value of this trap.
 java.lang.String getEnterpriseString()
          Gets the enterprise name of this trap.
 java.lang.String getModuleName()
          Gets the name of the module this trap is defined.
 java.lang.String getName()
          Gets the name of this trap.
 java.lang.String getReference()
          Gets the value of the REFERENCE clause.
 int getValue()
          Gets the generic or specific trap number.
 java.util.Vector getVariables()
          Gets the variables as a vector of strings.
 java.lang.String toString()
          Returns the name of this trap.
 java.lang.String toTagString()
          Gives the name and complete description of the trap like the MIB definition.
 
Methods inherited from class com.adventnet.snmp.mibs.MibTrap
getTrapType, readElements, readElements
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

moduleName

java.lang.String moduleName

name

java.lang.String name

enterprise

java.lang.String enterprise

description

java.lang.String description

reference

java.lang.String reference

variables

java.util.Vector variables

value

int value

queryString

java.lang.String queryString

rs

java.sql.ResultSet rs

tableName

java.lang.String tableName

jMibOps

JdbcMibOperations jMibOps
Constructor Detail

JdbcMibTrap

public JdbcMibTrap()

JdbcMibTrap

JdbcMibTrap(java.lang.String modulename,
            java.lang.String Name,
            JdbcMibOperations jdbcMibOps)
Method Detail

getModuleName

public java.lang.String getModuleName()
Description copied from class: MibTrap
Gets the name of the module this trap is defined.
Overrides:
getModuleName in class MibTrap
Tags copied from class: MibTrap
Returns:
String - the name of the module in which this trap is defined.

getName

public java.lang.String getName()
Description copied from class: MibTrap
Gets the name of this trap. Same as the toString() method.
Overrides:
getName in class MibTrap
Tags copied from class: MibTrap
Returns:
String - the name of this trap.
See Also:
MibTrap.toString()

getValue

public int getValue()
Description copied from class: MibTrap
Gets the generic or specific trap number. This method returns the trap number as specfied in the TRAP definition of the MIB

The type of the trap whether generic or specific type can be known from the getTrapType() method.

Overrides:
getValue in class MibTrap
Tags copied from class: MibTrap
Returns:
int - a non-negative value.
See Also:
MibTrap.getTrapType()

getEnterprise

public SnmpOID getEnterprise()
Description copied from class: MibTrap
Gets the enterprise value of this trap.

If the enterprise value is "snmp", then the trap is a generic trap. Then this method will return the SnmpOID value of "snmp" i.e. '.1.3.6.1.2.1.11'.

If the enterprise value is other than "snmp", then the trap is a specific trap and the enterprise value should be registered under the enterprise oid(.1.3.6.1.4.1)

If you want the enterprise value as a String, then the method getEnterpriseString() can be used.

Overrides:
getEnterprise in class MibTrap
Tags copied from class: MibTrap
Returns:
SnmpOID instance. The SnmpOID value of this enterprise string.
See Also:
MibTrap.getEnterpriseString()

getEnterpriseString

public java.lang.String getEnterpriseString()
Description copied from class: MibTrap
Gets the enterprise name of this trap.

When the value specified for the ENTERPRISE clause is 'snmp' (iso(1).org(3).dod(6).internet(1).mgmt(2).mib(1).snmp(11)), then the trap is a generic trap.
Otherwise the trap is a specific trap.

For the specific trap the enterprise value should be registered under the enterprise oid(.1.3.6.1.4.1)

This method returns the value specified in the ENTERPRISE clause of the TRAP-TYPE definition.

If you want the enterprise value as an SnmpOID instance, then the method getEnterprise() can be used.

Overrides:
getEnterpriseString in class MibTrap
Tags copied from class: MibTrap
Returns:
the Enterprise string for this trap

getVariables

public java.util.Vector getVariables()
Description copied from class: MibTrap
Gets the variables as a vector of strings.

The optional VARIABLES clause of the TRAP-TYPE construct is used to specify one or more scalar or columnar objects whose value describes the event.

The elements of the Vector returned by this method are the values present in the VARIABLES clause of the TRAP-TYPE definition.

Overrides:
getVariables in class MibTrap
Tags copied from class: MibTrap
Returns:
Vector of variable names if present, else return the empty Vector.

getDescription

public java.lang.String getDescription()
Description copied from class: MibTrap
Gets the value of the DESCRIPTION clause.
Overrides:
getDescription in class MibTrap
Tags copied from class: MibTrap
Returns:
the description string if present, else empty string.

getReference

public java.lang.String getReference()
Description copied from class: MibTrap
Gets the value of the REFERENCE clause.
Overrides:
getReference in class MibTrap
Tags copied from class: MibTrap
Returns:
the reference string if present, else return the empty string.

toString

public java.lang.String toString()
Description copied from class: MibTrap
Returns the name of this trap. Similar to getName()
Overrides:
toString in class MibTrap
Tags copied from class: MibTrap
Returns:
the name of this trap.
See Also:
MibTrap.getName()

toTagString

public java.lang.String toTagString()
Description copied from class: MibTrap
Gives the name and complete description of the trap like the MIB definition.
Overrides:
toTagString in class MibTrap
Tags copied from class: MibTrap
Returns:
a detailed description of this trap.