directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r441706 - /directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java
Date Sat, 09 Sep 2006 00:54:39 GMT
Author: elecharny
Date: Fri Sep  8 17:54:38 2006
New Revision: 441706

URL: http://svn.apache.org/viewvc?view=rev&rev=441706
Log:
Added an enum with all the universal tags, constructed.

Added:
    directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java

Added: directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java
URL: http://svn.apache.org/viewvc/directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java?view=auto&rev=441706
==============================================================================
--- directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java
(added)
+++ directory/sandbox/akarasulu/apacheds-2.0/shared/asn1/src/main/java/org/apache/directory/shared/asn1/ber/ConstructedUniversalTags.java
Fri Sep  8 17:54:38 2006
@@ -0,0 +1,237 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *  
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *  
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License. 
+ *  
+ */
+package org.apache.directory.shared.asn1.ber;
+
+/**
+ * Enum for ASN.1 UNIVERSAL constructed class tags. These enums are all
+ * those are constructed by essence
+ * <p>
+ * These tags can have one of the following values:
+ * </p>
+ * <p>
+ * </p>
+ * <table border="1" cellspacing="1" width="60%">
+ * <tr>
+ * <th>Id</th>
+ * <th>Usage</th>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 20]</td>
+ * <td>reserved for BER</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 21]</td>
+ * <td>BOOLEAN</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 22]</td>
+ * <td>INTEGER</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 23]</td>
+ * <td>BIT STRING</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 24]</td>
+ * <td>OCTET STRING</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 25]</td>
+ * <td>NULL</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 26]</td>
+ * <td>OBJECT IDENTIFIER</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 27]</td>
+ * <td>ObjectDescriptor</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 28]</td>
+ * <td>EXTERNAL, INSTANCE OF</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 29]</td>
+ * <td>REAL</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2A]</td>
+ * <td>ENUMERATED</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2B]</td>
+ * <td>EMBEDDED PDV</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2C]</td>
+ * <td>UTF8String</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2D]</td>
+ * <td>RELATIVE-OID</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2E]</td>
+ * <td>reserved for future use</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 2F]</td>
+ * <td>reserved for future use</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 30]</td>
+ * <td>SEQUENCE, SEQUENCE OF</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 31]</td>
+ * <td>SET, SET OF</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 32]</td>
+ * <td>NumericString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 33]</td>
+ * <td>PrintableString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 34]</td>
+ * <td>TeletexString, T61String</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 35]</td>
+ * <td>VideotexString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 36]</td>
+ * <td>IA5String</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 37]</td>
+ * <td>UTCTime</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 38]</td>
+ * <td>GeneralizedTime</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 39]</td>
+ * <td>GraphicString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3A]</td>
+ * <td>VisibleString, ISO646String</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3B]</td>
+ * <td>GeneralString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3C]</td>
+ * <td>UniversalString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3D]</td>
+ * <td>CHARACTER STRING</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3E]</td>
+ * <td>BMPString</td>
+ * </tr>
+ * <tr>
+ * <td>[UNIVERSAL 3F]</td>
+ * <td>reserved for future use</td>
+ * </tr>
+ * </table>
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public enum ConstructedUniversalTags
+{
+    /** The values */
+    RESERVED_0( (byte)0x20, "RESERVED_0"),
+    BOOLEAN( (byte)0x21, "BOOLEAN"),
+    INTEGER( (byte)0x22, "INTEGER"),
+    BIT_STRING( (byte)0x23, "BIT_STRING"),
+    OCTET_STRING( (byte)0x24, "OCTET_STRING"),
+    NULL( (byte)0x25, "NULL"),
+    OBJECT_IDENTIFIER( (byte)0x26, "OBJECT_IDENTIFIER"),
+    OBJECT_DESCRIPTOR( (byte)0x27, "OBJECT_DESCRIPTOR"),
+    EXTERNAL_INSTANCE_OF( (byte)0x28, "EXTERNAL_INSTANCE_OF"),
+    REAL( (byte)0x29, "REAL"),
+    ENUMERATED( (byte)0x2A, "ENUMERATED"),
+    EMBEDDED_PDV( (byte)0x2B, "EMBEDDED_PDV"),
+    UTF8_STRING( (byte)0x2C, "UTF8_STRING"),
+    RELATIVE_OID( (byte)0x2D, "RELATIVE_OID"),
+    RESERVED_14( (byte)0x2E, "RESERVED_14"),
+    RESERVED_15( (byte)0x2F, "RESERVED_15"),
+    SEQUENCE_SEQUENCE_OF( (byte)0x30, "SEQUENCE_SEQUENCE_OF"),
+    SET_SET_OF( (byte)0x31, "SET_SET_OF"),
+    NUMERIC_STRING( (byte)0x32, "NUMERIC_STRING"),
+    PRINTABLE_STRING( (byte)0x33, "PRINTABLE_STRING"),
+    TELETEX_STRING( (byte)0x34, "TELETEX_STRING"),
+    VIDEOTEX_STRING( (byte)0x35, "VIDEOTEX_STRING"),
+    IA5_STRING( (byte)0x36, "IA5_STRING"),
+    UTC_TIME( (byte)0x37, "UTC_TIME"),
+    GENERALIZED_TIME( (byte)0x38, "GENERALIZED_TIME"),
+    GRAPHIC_STRING( (byte)0x39, "GRAPHIC_STRING"),
+    VISIBLE_STRING( (byte)0x3A, "VISIBLE_STRING"),
+    GENERAL_STRING( (byte)0x3B, "GENERAL_STRING"),
+    UNIVERSAL_STRING( (byte)0x3C, "UNIVERSAL_STRING"),
+    CHARACTER_STRING( (byte)0x3D, "CHARACTER_STRING"),
+    BMP_STRING( (byte)0x3E, "BMP_STRING"),
+    RESERVED_31( (byte)0x3F, "RESERVED_31");
+    
+    
+    /** The byte value for a tag */
+    private byte value;
+    
+    /** The String value of a tag */
+    private String string;
+    
+    /**
+     * Creates a new instance of UniversalTags.
+     *
+     * @param value The byte of the created tag
+     * @param string The String of the created tag
+     */
+    private ConstructedUniversalTags( byte value, String string )
+    {
+        this.value = value;
+        this.string = string;
+    }
+ 
+    /**
+     * @return The byte associated with this tag
+     */
+    public byte getValue()
+    {
+        return value;
+    }
+    
+    /**
+     * @return The name of this tag
+     */
+    public String getString()
+    {
+        return string;
+    }
+}



Mime
View raw message