public class SimpleOIDTextFormat extends java.lang.Object implements OIDTextFormat
SimpleOIDTextFormat
implements a simple textual
representation for object IDs as dotted string.Constructor and Description |
---|
SimpleOIDTextFormat()
Creates a simple OID text format.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
format(int[] value)
Returns a textual representation of a raw object ID as dotted
string ("1.3.6.1.4").
|
java.lang.String |
formatForRoundTrip(int[] value)
Returns a textual representation of a raw object ID as dotted
string ("1.3.6.1.4").
|
static java.lang.String |
formatOID(int[] value)
Returns a textual representation of a raw object ID as dotted
string ("1.3.6.1.4").
|
int[] |
parse(java.lang.String text)
Parses a textual representation of an object ID as dotted string
(e.g.
|
static int[] |
parseOID(java.lang.String text)
Parses a textual representation of an object ID as dotted string
(e.g.
|
public SimpleOIDTextFormat()
public static java.lang.String formatOID(int[] value)
value
- the OID value to format.public java.lang.String format(int[] value)
format
in interface OIDTextFormat
value
- the OID value to format.public java.lang.String formatForRoundTrip(int[] value)
format(int[])
.formatForRoundTrip
in interface OIDTextFormat
value
- the OID value to format.public static int[] parseOID(java.lang.String text) throws java.text.ParseException
text
- a textual representation of an OID.java.text.ParseException
- if the OID cannot be parsed successfully.public int[] parse(java.lang.String text) throws java.text.ParseException
parse
in interface OIDTextFormat
text
- a textual representation of an OID.java.text.ParseException
- if the OID cannot be parsed successfully.