Package net.aifusion.asn
Class RelativeOidValue
java.lang.Object
net.aifusion.asn.AsnValue
net.aifusion.asn.RelativeOidValue
Class to pack a relative OID
- Author:
- Sharad Singhal
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic RelativeOidValue
create
(byte[] buffer, int blen, int cursor) boolean
byte[]
Get the encoded value for this ASN.1 value.long[]
getValue()
Get the value of this OIDint
hashCode()
toAsnString
(String prefix) Get a (semi) ASN.1 notation for this value.toString()
Methods inherited from class net.aifusion.asn.AsnValue
getLength, getTag, getTagClass, getTagEncoding, getTagNumber, toHex, toHex, toHex, toHex
-
Constructor Details
-
RelativeOidValue
public RelativeOidValue(long[] oidValues) Create a Relative OID value- Parameters:
oidValues
- - array containing relative OID components, with oidValues[0] being the leftmost component
-
-
Method Details
-
create
-
getValue
public long[] getValue()Get the value of this OID- Returns:
- - array containing OID values. Element 0 is the root OID
-
toAsnString
Description copied from class:AsnValue
Get a (semi) ASN.1 notation for this value.- Overrides:
toAsnString
in classAsnValue
- Parameters:
prefix
- - prefix to add to each line- Returns:
- - string containing the ASN.1 value
-
equals
-
hashCode
public int hashCode() -
getEncodedValue
public byte[] getEncodedValue()Description copied from class:AsnValue
Get the encoded value for this ASN.1 value. This method should be implemented by subclasses to provide the encoded ASN.1 value- Specified by:
getEncodedValue
in classAsnValue
- Returns:
- byte [] containing encoded value for this ASN.1 value (including tag, length, content)
-
toString
-