All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class jsnmp.SnmpInt

java.lang.Object
   |
   +----jsnmp.SnmpVar
           |
           +----jsnmp.SnmpInt

public class SnmpInt
extends SnmpVar
Handles each occurance of an ASN.1 INTEGER mib variable, by extending the SnmpVar abstract class.


Variable Index

 o value

Constructor Index

 o SnmpInt()
Creates an SnmpInt variable with a zero initial value.
 o SnmpInt(int)
Creates an SnmpInt variable with an initial value of i.

Method Index

 o decode(ByteArrayInputStream, int)
Decodes an ASN.1 INTEGER to a BigInteger.
 o encode()
Encodes an integer (arbitrary precision) into an ASN.1 INTEGER.
 o getValue()
Returns the value of the ASN.1 INTEGER variable.
 o toString()
Returns the value of the INTEGER variable as a printable string.

Variables

 o value
 private BigInteger value

Constructors

 o SnmpInt
 public SnmpInt()
Creates an SnmpInt variable with a zero initial value.

 o SnmpInt
 public SnmpInt(int i)
Creates an SnmpInt variable with an initial value of i.

Methods

 o getValue
 public Object getValue()
Returns the value of the ASN.1 INTEGER variable.

Overrides:
getValue in class SnmpVar
 o toString
 public String toString()
Returns the value of the INTEGER variable as a printable string.

Overrides:
toString in class SnmpVar
 o encode
 public byte[] encode()
Encodes an integer (arbitrary precision) into an ASN.1 INTEGER.

Overrides:
encode in class SnmpVar
 o decode
 public void decode(ByteArrayInputStream pdu,
                    int length) throws SnmpException
Decodes an ASN.1 INTEGER to a BigInteger.

Overrides:
decode in class SnmpVar

All Packages  Class Hierarchy  This Package  Previous  Next  Index