| |
|
| java.lang.Object snmp.SNMPBERCodec
SNMPBERCodec | public class SNMPBERCodec (Code) | | SNMPBERCodec defines methods for converting from ASN.1 BER encoding to SNMPObject subclasses. The extraction
process usually produces a tree structure of objects with an SNMPSequence object at the root; this
is the usual behavior when a received encoded message is received from an SNMP device.
|
Method Summary | |
public static byte[] | encodeLength(int length) | public static SNMPObject | extractEncoding(SNMPTLV theTLV) Extracts an SNMP object given its type, length, value triple as an SNMPTLV object. | public static SNMPTLV | extractNextTLV(byte[] enc, int position) Extracts the type, length and value of the SNMP object whose BER encoding begins at the
specified position in the given byte array. |
SNMPBITSTRING | final public static byte SNMPBITSTRING(Code) | | |
SNMPCOUNTER32 | final public static byte SNMPCOUNTER32(Code) | | |
SNMPCOUNTER64 | final public static byte SNMPCOUNTER64(Code) | | |
SNMPGAUGE32 | final public static byte SNMPGAUGE32(Code) | | |
SNMPGETNEXTREQUEST | final public static byte SNMPGETNEXTREQUEST(Code) | | |
SNMPGETREQUEST | final public static byte SNMPGETREQUEST(Code) | | |
SNMPGETRESPONSE | final public static byte SNMPGETRESPONSE(Code) | | |
SNMPINTEGER | final public static byte SNMPINTEGER(Code) | | |
SNMPIPADDRESS | final public static byte SNMPIPADDRESS(Code) | | |
SNMPNSAPADDRESS | final public static byte SNMPNSAPADDRESS(Code) | | |
SNMPNULL | final public static byte SNMPNULL(Code) | | |
SNMPOBJECTIDENTIFIER | final public static byte SNMPOBJECTIDENTIFIER(Code) | | |
SNMPOCTETSTRING | final public static byte SNMPOCTETSTRING(Code) | | |
SNMPOPAQUE | final public static byte SNMPOPAQUE(Code) | | |
SNMPSEQUENCE | final public static byte SNMPSEQUENCE(Code) | | |
SNMPSETREQUEST | final public static byte SNMPSETREQUEST(Code) | | |
SNMPTIMETICKS | final public static byte SNMPTIMETICKS(Code) | | |
SNMPTRAP | final public static byte SNMPTRAP(Code) | | |
SNMPUINTEGER32 | final public static byte SNMPUINTEGER32(Code) | | |
SNMPUNKNOWNOBJECT | final public static byte SNMPUNKNOWNOBJECT(Code) | | |
SNMPv2BULKREQUEST | final public static byte SNMPv2BULKREQUEST(Code) | | |
SNMPv2INFORMREQUEST | final public static byte SNMPv2INFORMREQUEST(Code) | | |
SNMPv2TRAP | final public static byte SNMPv2TRAP(Code) | | |
SNMPv2pAUTHORIZEDMESSAGE | final public static byte SNMPv2pAUTHORIZEDMESSAGE(Code) | | |
SNMPv2pCOMMUNICATION | final public static byte SNMPv2pCOMMUNICATION(Code) | | |
SNMPv2pENCRYPTEDDATA | final public static byte SNMPv2pENCRYPTEDDATA(Code) | | |
SNMPv2pENCRYPTEDMESSAGE | final public static byte SNMPv2pENCRYPTEDMESSAGE(Code) | | |
encodeLength | public static byte[] encodeLength(int length)(Code) | | Utility function for encoding a length as a BER byte sequence
|
extractEncoding | public static SNMPObject extractEncoding(SNMPTLV theTLV) throws SNMPBadValueException(Code) | | Extracts an SNMP object given its type, length, value triple as an SNMPTLV object.
Called by SNMPObject subclass constructors.
throws: SNMPBadValueException - Indicates byte array in value field is uninterprettable forspecified SNMP object type. |
extractNextTLV | public static SNMPTLV extractNextTLV(byte[] enc, int position) throws SNMPBadValueException(Code) | | Extracts the type, length and value of the SNMP object whose BER encoding begins at the
specified position in the given byte array. Throws an SNMPBadValueException if there's
any problem with the extraction.
|
|
|
|