Package org.opennms.netmgt.snmp
Class SnmpObjId
- java.lang.Object
-
- org.opennms.netmgt.snmp.SnmpObjId
-
- All Implemented Interfaces:
Comparable<SnmpObjId>
- Direct Known Subclasses:
SnmpInstId
public class SnmpObjId extends Object implements Comparable<SnmpObjId>
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSnmpObjId()protectedSnmpObjId(int[] ids)These constructors are private.SnmpObjId(int[] ids, boolean clone)These constructors are private.protectedSnmpObjId(String oid)These constructors are private.protectedSnmpObjId(SnmpObjId oid)These constructors are private.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleanaddPrefixDotInToString()SnmpObjIdappend(int[] instIds)SnmpObjIdappend(String inst)SnmpObjIdappend(SnmpObjId inst)intcompareTo(SnmpObjId o)static int[]convertStringToInts(String oid)SnmpObjIddecrement()booleanequals(Object obj)static SnmpObjIdget(int[] ids)static SnmpObjIdget(String oid)static SnmpObjIdget(String objId, String instance)static SnmpObjIdget(SnmpObjId oid)static SnmpObjIdget(SnmpObjId objId, String instance)static SnmpObjIdget(SnmpObjId objId, SnmpObjId instance)int[]getIds()SnmpInstIdgetInstance(SnmpObjId base)intgetLastSubId()SnmpObjIdgetPrefix(int length)intgetSubIdAt(int index)inthashCode()booleanisPrefixOf(SnmpObjId other)booleanisSuccessorOf(SnmpObjId base)If requesting a GETNEXT on the given base OID, would the current OID be expected in a response? Returnstrueif this OID is a successor (greater than) the given OID, orfalseotherwise.intlength()StringtoString()
-
-
-
Constructor Detail
-
SnmpObjId
protected SnmpObjId()
-
SnmpObjId
public SnmpObjId(int[] ids, boolean clone)These constructors are private. The get method should be called to create a new oid
-
SnmpObjId
protected SnmpObjId(int[] ids)
These constructors are private. The get method should be called to create a new oid
-
SnmpObjId
protected SnmpObjId(String oid)
These constructors are private. The get method should be called to create a new oid
-
SnmpObjId
protected SnmpObjId(SnmpObjId oid)
These constructors are private. The get method should be called to create a new oid
-
-
Method Detail
-
getIds
public int[] getIds()
-
convertStringToInts
public static int[] convertStringToInts(String oid)
-
addPrefixDotInToString
protected boolean addPrefixDotInToString()
-
compareTo
public int compareTo(SnmpObjId o)
- Specified by:
compareToin interfaceComparable<SnmpObjId>
-
append
public SnmpObjId append(int[] instIds)
-
get
public static SnmpObjId get(int[] ids)
-
isPrefixOf
public boolean isPrefixOf(SnmpObjId other)
-
getInstance
public SnmpInstId getInstance(SnmpObjId base)
-
length
public int length()
-
getPrefix
public SnmpObjId getPrefix(int length)
-
getSubIdAt
public int getSubIdAt(int index)
-
getLastSubId
public int getLastSubId()
-
decrement
public SnmpObjId decrement()
-
isSuccessorOf
public boolean isSuccessorOf(SnmpObjId base)
If requesting a GETNEXT on the given base OID, would the current OID be expected in a response? Returnstrueif this OID is a successor (greater than) the given OID, orfalseotherwise.- Parameters:
base- base oid against which to compare- Returns:
- true if this OID is a successor of the "base" oid, false otherwise
-
-