snmp
Class SNMPObject

java.lang.Object
  extended bysnmp.SNMPObject
Direct Known Subclasses:
SNMPInteger, SNMPNull, SNMPObjectIdentifier, SNMPOctetString, SNMPSequence, SNMPUnknownObject

public abstract class SNMPObject
extends java.lang.Object

Abstract base class of all SNMP data type classes.


Constructor Summary
SNMPObject()
           
 
Method Summary
 boolean equals(java.lang.Object other)
          Compares two SNMPObject subclass objects by checking their values for equality.
protected abstract  byte[] getBEREncoding()
          Must return the BER byte encoding (type, length, value) of the SNMP object.
abstract  java.lang.Object getValue()
          Must return a Java object appropriate to represent the value/data contained in the SNMP object
 int hashCode()
          Generates a hash value so SNMP objects can be used in Hashtables.
abstract  void setValue(java.lang.Object o)
          Must set the value of the SNMP object when supplied with an appropriate Java object containing an appropriate value.
abstract  java.lang.String toString()
          Should return an appropriate human-readable representation of the stored value.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SNMPObject

public SNMPObject()
Method Detail

getValue

public abstract java.lang.Object getValue()
Must return a Java object appropriate to represent the value/data contained in the SNMP object


setValue

public abstract void setValue(java.lang.Object o)
                       throws SNMPBadValueException
Must set the value of the SNMP object when supplied with an appropriate Java object containing an appropriate value.

Throws:
SNMPBadValueException

toString

public abstract java.lang.String toString()
Should return an appropriate human-readable representation of the stored value.


getBEREncoding

protected abstract byte[] getBEREncoding()
Must return the BER byte encoding (type, length, value) of the SNMP object.


equals

public boolean equals(java.lang.Object other)
Compares two SNMPObject subclass objects by checking their values for equality.


hashCode

public int hashCode()
Generates a hash value so SNMP objects can be used in Hashtables.