org.apache.directory.shared.asn1.ber.tlv
Class UniversalTag

java.lang.Object
  extended by org.apache.directory.shared.asn1.ber.tlv.UniversalTag

public class UniversalTag
extends Object

Enum for ASN.1 UNIVERSAL class tags. The tags values are constructed using the SNACC representation for tags without the primitive/constructed bit. This is done because several bit, octet and character string types can be encoded as primitives or as constructed types to chunk the value out.

These tags can have one of the following values:

Id Usage
[UNIVERSAL 0] reserved for BER
[UNIVERSAL 1] BOOLEAN
[UNIVERSAL 2] INTEGER
[UNIVERSAL 3] BIT STRING
[UNIVERSAL 4] OCTET STRING
[UNIVERSAL 5] NULL
[UNIVERSAL 6] OBJECT IDENTIFIER
[UNIVERSAL 7] ObjectDescriptor
[UNIVERSAL 8] EXTERNAL, INSTANCE OF
[UNIVERSAL 9] REAL
[UNIVERSAL 10] ENUMERATED
[UNIVERSAL 11] EMBEDDED PDV
[UNIVERSAL 12] UTF8String
[UNIVERSAL 13] RELATIVE-OID
[UNIVERSAL 14] reserved for future use
[UNIVERSAL 15] reserved for future use
[UNIVERSAL 16] SEQUENCE, SEQUENCE OF
[UNIVERSAL 17] SET, SET OF
[UNIVERSAL 18] NumericString
[UNIVERSAL 19] PrintableString
[UNIVERSAL 20] TeletexString, T61String
[UNIVERSAL 21] VideotexString
[UNIVERSAL 22] IA5String
[UNIVERSAL 23] UTCTime
[UNIVERSAL 24] GeneralizedTime
[UNIVERSAL 25] GraphicString
[UNIVERSAL 26] VisibleString, ISO646String
[UNIVERSAL 27] GeneralString
[UNIVERSAL 28] UniversalString
[UNIVERSAL 29] CHARACTER STRING
[UNIVERSAL 30] BMPString
[UNIVERSAL 31] reserved for future use

Author:
Apache Directory Project

Field Summary
static int BIT_STRING
          value for the tag
static int BMP_STRING
          value for the tag
static int BOOLEAN
          value for the tag
static byte BOOLEAN_TAG
          ASN.1 primitive tag values
static int CHARACTER_STRING
          value for the tag
static int EMBEDDED_PDV
          value for the tag
static int ENUMERATED
          value for the tag
static byte ENUMERATED_TAG
           
static int EXTERNAL_INSTANCE_OF
          value for the tag
static int GENERAL_STRING
          value for the tag
static int GENERALIZED_TIME
          value for the tag
static int GRAPHIC_STRING
          value for the tag
static int IA5_STRING
          value for the tag
static int INTEGER
          value for the tag
static byte INTEGER_TAG
           
static int NULL
          value for the tag
static int NUMERIC_STRING
          value for the tag
static int OBJECT_DESCRIPTOR
          value for the tag
static int OBJECT_IDENTIFIER
          value for the tag
static int OCTET_STRING
          value for the tag
static byte OCTET_STRING_TAG
           
static int PRINTABLE_STRING
          value for the tag
static int REAL
          value for the tag
static int RELATIVE_OID
          value for the tag
static int RESERVED_0
          value for the tag
static int RESERVED_14
          value for the tag
static int RESERVED_15
          value for the tag
static int RESERVED_31
          value for the tag
static int SEQUENCE_SEQUENCE_OF
          value for the tag
static byte SEQUENCE_TAG
           
static int SET_SET_OF
          value for the tag
static byte SET_TAG
           
static int TELETEX_STRING
          value for the tag
static int UNIVERSAL_STRING
          value for the tag
static int UTC_TIME
          value for the tag
static int UTF8_STRING
          value for the tag
static int VIDEOTEX_STRING
          value for the tag
static int VISIBLE_STRING
          value for the tag
 
Constructor Summary
UniversalTag()
           
 
Method Summary
static String toString(int tag)
          Gets the ASN.1 UNIVERSAL type tag's enum using a tag value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESERVED_0

public static final int RESERVED_0
value for the tag

See Also:
Constant Field Values

BOOLEAN

public static final int BOOLEAN
value for the tag

See Also:
Constant Field Values

INTEGER

public static final int INTEGER
value for the tag

See Also:
Constant Field Values

BIT_STRING

public static final int BIT_STRING
value for the tag

See Also:
Constant Field Values

OCTET_STRING

public static final int OCTET_STRING
value for the tag

See Also:
Constant Field Values

NULL

public static final int NULL
value for the tag

See Also:
Constant Field Values

OBJECT_IDENTIFIER

public static final int OBJECT_IDENTIFIER
value for the tag

See Also:
Constant Field Values

OBJECT_DESCRIPTOR

public static final int OBJECT_DESCRIPTOR
value for the tag

See Also:
Constant Field Values

EXTERNAL_INSTANCE_OF

public static final int EXTERNAL_INSTANCE_OF
value for the tag

See Also:
Constant Field Values

REAL

public static final int REAL
value for the tag

See Also:
Constant Field Values

ENUMERATED

public static final int ENUMERATED
value for the tag

See Also:
Constant Field Values

EMBEDDED_PDV

public static final int EMBEDDED_PDV
value for the tag

See Also:
Constant Field Values

UTF8_STRING

public static final int UTF8_STRING
value for the tag

See Also:
Constant Field Values

RELATIVE_OID

public static final int RELATIVE_OID
value for the tag

See Also:
Constant Field Values

RESERVED_14

public static final int RESERVED_14
value for the tag

See Also:
Constant Field Values

RESERVED_15

public static final int RESERVED_15
value for the tag

See Also:
Constant Field Values

SEQUENCE_SEQUENCE_OF

public static final int SEQUENCE_SEQUENCE_OF
value for the tag

See Also:
Constant Field Values

SET_SET_OF

public static final int SET_SET_OF
value for the tag

See Also:
Constant Field Values

NUMERIC_STRING

public static final int NUMERIC_STRING
value for the tag

See Also:
Constant Field Values

PRINTABLE_STRING

public static final int PRINTABLE_STRING
value for the tag

See Also:
Constant Field Values

TELETEX_STRING

public static final int TELETEX_STRING
value for the tag

See Also:
Constant Field Values

VIDEOTEX_STRING

public static final int VIDEOTEX_STRING
value for the tag

See Also:
Constant Field Values

IA5_STRING

public static final int IA5_STRING
value for the tag

See Also:
Constant Field Values

UTC_TIME

public static final int UTC_TIME
value for the tag

See Also:
Constant Field Values

GENERALIZED_TIME

public static final int GENERALIZED_TIME
value for the tag

See Also:
Constant Field Values

GRAPHIC_STRING

public static final int GRAPHIC_STRING
value for the tag

See Also:
Constant Field Values

VISIBLE_STRING

public static final int VISIBLE_STRING
value for the tag

See Also:
Constant Field Values

GENERAL_STRING

public static final int GENERAL_STRING
value for the tag

See Also:
Constant Field Values

UNIVERSAL_STRING

public static final int UNIVERSAL_STRING
value for the tag

See Also:
Constant Field Values

CHARACTER_STRING

public static final int CHARACTER_STRING
value for the tag

See Also:
Constant Field Values

BMP_STRING

public static final int BMP_STRING
value for the tag

See Also:
Constant Field Values

RESERVED_31

public static final int RESERVED_31
value for the tag

See Also:
Constant Field Values

BOOLEAN_TAG

public static final byte BOOLEAN_TAG
ASN.1 primitive tag values

See Also:
Constant Field Values

INTEGER_TAG

public static final byte INTEGER_TAG
See Also:
Constant Field Values

OCTET_STRING_TAG

public static final byte OCTET_STRING_TAG
See Also:
Constant Field Values

ENUMERATED_TAG

public static final byte ENUMERATED_TAG
See Also:
Constant Field Values

SEQUENCE_TAG

public static final byte SEQUENCE_TAG
See Also:
Constant Field Values

SET_TAG

public static final byte SET_TAG
See Also:
Constant Field Values
Constructor Detail

UniversalTag

public UniversalTag()
Method Detail

toString

public static String toString(int tag)
Gets the ASN.1 UNIVERSAL type tag's enum using a tag value.

Parameters:
tag - the first octet of the TLV
Returns:
the valued enum for the ASN.1 UNIVERSAL type tag


Copyright © 2004-2012. All Rights Reserved.