draft-legg-xed-asd-06.txt  -->   draft-legg-xed-asd-07.txt

view Side-By-Side changes






INTERNET-DRAFT                                                   S. Legg
draft-legg-xed-asd-06.txt
draft-legg-xed-asd-07.txt                                        eB2Bcom
Intended Category: Standards Track                      October 20,                     December 22, 2006


                   Abstract Syntax Notation X (ASN.X)

                  Copyright (C) The Internet Society IETF Trust (2006).

   Status of This Memo

   By submitting this Internet-draft, each author represents that any
   applicable patent or other IPR claims of which he or she is aware
   have been or will be disclosed, and any of which he or she becomes
   aware will be disclosed, in accordance with Section 6 of BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as
   Internet-Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress".

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/1id-abstracts.html

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html

   Technical discussion of this document should take place on the XED
   developers mailing list <xeddev@eb2bcom.com>.  Please send editorial
   comments directly to the editor <steven.legg@eb2bcom.com>.  Further
   information is available on the XED website: www.xmled.info.

   This Internet-Draft expires on 20 April 22 June 2007.


Abstract

   Abstract Syntax Notation X (ASN.X) is a semantically equivalent
   Extensible Markup Language (XML) representation for Abstract Syntax
   Notation One (ASN.1) specifications.  ASN.X completely avoids the
   numerous ambiguities inherent in the ASN.1 language, therefore
   specifications written in ASN.X
   documents are much easier to parse and manage
   than original ASN.1 specifications.  ASN.X, together with the Robust XML Encoding Rules



Legg                      Expires 20 April 22 June 2007                  [Page 1]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   XML Encoding Rules (RXER), constitutes a schema language for XML
   documents that offers, through other ASN.1 encoding rules,
   alternative compact binary encodings for XML instance documents.

Table of Contents

   1. Introduction ....................................................3
   2. Conventions .....................................................5
   3. General Considerations ..........................................5
      3.1. Annotations ................................................7
   4. ModuleDefinition Translation ....................................8
   5. Translation of Assignments .....................................10
      5.1. Referencing Named Constructs ..............................11
      5.2. Importing Namespaces ......................................12
      5.3. TypeAssignment Translation ................................13
      5.4. ValueAssignment and XMLValueAssignment Translation ........14
      5.5. ValueSetTypeAssignment Translation ........................14
      5.6. ObjectClassAssignment Translation .........................15
      5.7. ObjectAssignment Translation ..............................15
      5.8. ObjectSetAssignment Translation ...........................16
      5.9. Parameterized Definitions .................................16 ParameterizedAssignment Translation .......................17
   6. Translation of Types ...........................................16 ...........................................17
      6.1. Identifier Replacement ....................................25 ....................................17
      6.2. DefinedType Translation ...................................26 ...................................18
      6.3. Translation of Predefined Built-in Types ...........................29 .............................20
      6.4. BitStringType Translation .................................30 .................................21
      6.5. IntegerType Translation ...................................31 ...................................22
      6.6. EnumeratedType Translation ................................33 ................................23
      6.7. PrefixedType Translation ..................................34 ..................................25
           6.7.1. Short Form TaggedType Translation ..................37 ..................27
           6.7.2. Long Form TaggedType Translation ...................38 ...................28
      6.8. SelectionType Translation  ................................39 .................................29
      6.9. InstanceOfType Translation ................................40 ................................30
      6.10. ObjectClassFieldType Translation .........................40 .........................31
      6.11. TypeFromObject and ValueSetFromObjects Translation .......40 .......31
      6.12. Translation of Combining Types ...........................41 ...........................32
           6.12.1. NamedType Translation .............................41 .............................32
           6.12.2. SequenceType Translation ..........................45 ..........................36
           6.12.3. SetType Translation ...............................47 ...............................38
           6.12.4. ChoiceType Translation ............................47 ............................38
           6.12.5. Translation of UNION Types ........................48 ........................39
           6.12.6. SequenceOfType Translation ........................49 ........................40
           6.12.7. Translation of LIST Types .........................50 .........................41
           6.12.8. SetOfType Translation .............................50 .............................41
           6.12.9. Effect of Insertion Encoding Instructions ...................51 .........42
      6.13. Translation of Constrained Types .........................51 .........................42
           6.13.1. Constraint Translation ............................54 ............................45
           6.13.2. UserDefinedConstraint Translation .................54 .................45



Legg                      Expires 20 April 22 June 2007                  [Page 2]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


           6.13.3. TableConstraint Translation .......................55 .......................46
           6.13.4. ContentsConstraint Translation ....................57 ....................48
           6.13.5. ExceptionSpec Translation .........................58 .........................49
   7. Translation of Values ..........................................59 ..........................................50
      7.1. Translation of Literal Values .............................60 .............................51
      7.2. Translation of Notational Values ..........................62 ..........................53
           7.2.1. DefinedValue Translation ...........................63 ...........................54
           7.2.2. BuiltinValue Translation ...........................64 ...........................55
           7.2.3. ValueFromObject Translation ........................67 ........................59
           7.2.4. ObjectClassFieldValue Translation ..................67 ..................59
   8. Translation of Value Sets ......................................68 ......................................60
      8.1. ElementSetSpecs Translation ...............................69 ...............................60
      8.2. ElementSetSpec Translation ................................69 ................................61
      8.3. SubtypeElements Translation ...............................70 ...............................62
           8.3.1. ValueRange Translation .............................71 .............................63
           8.3.2. InnerTypeConstraints Translation ...................72 ...................64
   9. Translation of Object Classes ..................................73 ..................................65
      9.1. DefinedObjectClass Translation ............................73 ............................65
      9.2. ObjectClassDefn Translation ...............................74 ...............................66
           9.2.1. TypeFieldSpec Translation ..........................75 ..........................66
           9.2.2. FixedTypeValueFieldSpec Translation ................76 ................67
           9.2.3. FixedTypeValueSetFieldSpec Translation .............77 .............69
           9.2.4. VariableTypeValueFieldSpec Translation .............78 .............70
           9.2.5. VariableTypeValueSetFieldSpec Translation ..........79 ..........71
           9.2.6. FieldName Translation ..............................81 ..............................73
           9.2.7. ObjectFieldSpec Translation ........................81 ........................73
           9.2.8. ObjectSetFieldSpec Translation .....................82 .....................74
   10. Translation of Objects ........................................84 ........................................75
      10.1. DefinedObject Translation ................................84 ................................75
      10.2. ObjectDefn Translation ...................................85 ...................................76
      10.3. ObjectFromObject Translation .............................86 .............................78
   11. Translation of Object Sets ....................................86 ....................................78
      11.1. DefinedObjectSet Translation .............................87 .............................79
      11.2. ObjectSetElements Translation ............................88 ............................80
            11.2.1. ObjectSetFromObjects Translation .................89 .................81
   12. Translation of Information From Objects .......................89 .......................81
   13. EncodingControlSections Translation ...........................90 of Parameterized Definitions ......................82
   14. EncodingControlSections Translation ...........................91
   15. Security Considerations .......................................90
   15. Acknowledgements ..............................................91 .......................................92
   16. Acknowledgements ..............................................92
   17. IANA Considerations ...........................................91
   17. ...........................................92
   18. References ....................................................91
      17.1. ....................................................92
      18.1. Normative References .....................................91
      17.2. .....................................92
      18.2. Informative References ...................................93 ...................................94
   Appendix A. ASN.1 for ASN.X .......................................93 .......................................95
   Appendix B. ASN.X for ASN.X ......................................113 ......................................115

1.  Introduction



Legg                      Expires 20 April 22 June 2007                  [Page 3]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   A full parser for the Abstract Syntax Notation One (ASN.1) language
   [X.680] is difficult to implement due to numerous ambiguities in the
   notation.  For example, certain notations for a Value are
   syntactically indistinguishable from notation for a ValueSet, Object,
   ObjectSet, DummyReference or SimpleTableConstraint.  An
   ObjectClassAssignment, ObjectAssignment or ObjectSetAssignment
   resembles respectively a TypeAssignment, ValueAssignment or
   ValueSetTypeAssignment.  A FixedTypeValueFieldSpec or
   FixedTypeValueSetFieldSpec resembles respectively an ObjectFieldSpec
   or ObjectSetFieldSpec, and an ObjectClassFieldType resembles
   InformationFromObjects.
   InformationFromObjects notation.  In general general, such ambiguities can
   only be resolved once the entire specification has been parsed.
   There are other notations that are not mutually ambiguous but still
   require several lexical tokens to be scanned before they can be
   distinguished from each other.  The difficulty of parsing ASN.1 is an
   impediment to its wider adoption.

   This document defines a semantically equivalent Extensible Markup
   Language (XML) [XML10][XML11] representation for ASN.1 specifications
   called Abstract Syntax Notation X (ASN.X).  An ASN.X module is a
   well-formed and valid XML document conforming to XML namespaces
   [XMLNS10][XMLNS11].  ASN.X completely avoids the inherent ambiguities
   of the ASN.1 language, therefore specifications written in ASN.X
   documents are
   much easier to parse and manage than original ASN.1 specifications.
   For example, any conformant XML processor forms the basis of an ASN.1
   toolkit.

   An ASN.X document is a well-formed and valid XML document conforming
   to XML namespaces [XMLNS10][XMLNS11].

   ASN.X, together with the Robust XML Encoding Rules (RXER) [RXER],
   constitutes a schema language for XML documents that offers, through
   other ASN.1 encoding rules, alternative compact binary encodings for
   XML instance documents conforming to an ASN.X specification.  ASN.X
   definitions can also incorporate type, element and attribute
   definitions from XML Schema [XSD1], [XSD1] documents, RELAX NG [RNG]
   documents or Document Type Definitions (DTDs) [XML10][XML11].

   ASN.X is defined in terms of rules for translating from an ASN.1
   specification.  This does not preclude an ASN.X document module being written
   directly without a pre-existing ASN.1 specification, module, however such an ASN.X document
   module is considered valid if and only if there exists, in principle,
   an ASN.1 specification module that when translated would yield the ASN.X document. module.

   The format for ASN.X has also been designed so that the content of an
   ASN.X document module conforms to the RXER encoding of an abstract value of an
   ASN.1 type, the ModuleDefinition type, presented in Appendix A.  This
   means that it is possible to decode an ASN.X document module using an RXER
   decoder and then re-encode the abstract value (for storage or
   transmission) using any of the other encoding rules for ASN.1.  Thus



Legg                      Expires 20 April 2007                 [Page 4]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006
   the "X" in ASN.X can be regarded as standing for either XML or RXER,



Legg                      Expires 22 June 2007                  [Page 4]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   or more generally, for any set of ASN.1 encoding rules.

   The ASN.X translation of the ASN.1 module in Appendix A is presented
   in Appendix B.

2.  Conventions

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED" and "MAY" in this document are
   to be interpreted as described in, in BCP 14, RFC 2119 [BCP14].  The key
   word "OPTIONAL" is exclusively used with its ASN.1 meaning.

   Throughout this document "type" shall be taken to mean an ASN.1 type,
   and "value" shall be taken to mean an ASN.1 abstract value.

   A reference to an ASN.1 production [X.680] (e.g., Type, NamedType) is
   a reference to the text in an ASN.1 specification corresponding to
   that production.

   The description of the translation of an ASN.1 module into an ASN.X
   document
   module makes use of definitions from the XML Information Set
   (Infoset) [ISET]. [INFOSET].  In particular, information item property names
   follow the Infoset convention of being shown in square brackets,
   e.g., [local name].  Literal values of Infoset properties are
   enclosed in double quotes, however the double quotes are not part of
   the property values.  In the sections that follow, "information item"
   will be abbreviated to "item", e.g., "element information item" is
   abbreviated to "element item".  Element items will be referred to by
   their [local name] in angle brackets, e.g., "the <type> element item"
   means the element item with the [local name] "type".  Attribute items
   will be referred to by their [local name], e.g., "the type attribute
   item" means the attribute item with the [local name] "type".

   This document uses the namespace prefix "asnx:" to stand for the
   namespace name "urn:ietf:params:xml:ns:asnx", though in practice any
   valid namespace prefix is permitted in ASN.X.

   Encoding instructions [X.680-1] referenced by name in this
   specification are encoding instructions for RXER [RXEREI].  The
   associated provisions do not apply to encoding instructions for other
   encoding rules that happen to have the same name.

   Code points for characters [UNICODE] are expressed using the Unicode
   convention U+n, where n is four to six hexadecimal digits, e.g., the
   space character is U+0020.

3.  General Considerations




Legg                      Expires 22 June 2007                  [Page 5]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   ASN.X is defined in terms of rules for translating an ASN.1 module



Legg                      Expires 20 April 2007                 [Page 5]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006
   into a synthetic Infoset.  This synthetic Infoset is then serialized
   into a well-formed and valid XML document (the ASN.X document) module) in the
   same manner that the synthetic Infoset for a non-canonical RXER
   encoding is serialized into an XML document (see Section 5.11 6.12 of the
   specification for RXER [RXER]).

      Aside: The serialization permits CDATA sections, character
      references and parsed entity references.  However, note that an
      ASN.X document module may be transferred as data in a protocol and that
      some protocols disallow entity references.

   Apart from the [document element] of the document item for an ASN.X
   document,
   module, the translation of some ASN.1 construct belongs to the
   [children] or [attributes] of an enclosing element item.

   Where the translation of the construct is an element item, it is
   appended to the [children] of the enclosing element item.  Elements
   MUST be appended to the [children] of the enclosing element item in
   the order described.  Translators MAY add white space character items
   (i.e., U+0020, U+0009, U+000D and U+000A) to the [children] of any
   element item (to improve the layout) except element items with the
   [local name] "literalValue", "fieldName" or "restrictBy".

      Aside: White space character items in the [children] of <fieldName> and
      <restrictBy> element items is explicitly covered under their
      respective descriptions.

   Where the translation of the construct is an attribute item item, it is
   added to the [attributes] of the enclosing element item.  The order
   of attribute items is not significant.  Translators MAY add leading
   and trailing white space characters to the [normalized value] of any
   attribute item except an attribute item with the [local name]
   "literalValue".

      Aside: An attribute or element item with the [local name]
      "literalValue" holds an RXER Infoset translation of an abstract
      value, and white space characters may be significant in that
      abstract value.  In most cases cases, RXER itself permits optional
      leading and trailing white space characters in the Infoset
      translation.

   Translators MAY add comment and processing instruction (PI) items to
   the [children] of any element item except an element item with the
   [local name] "literalValue".

      Aside: In most cases cases, RXER itself permits comment and PI items in
      the [children] of the element items with the [local name]
      "literalValue".



Legg                      Expires 20 April 22 June 2007                  [Page 6]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      "literalValue".

      Aside: Note that an ASN.X document module may be transferred as data in a
      protocol and that some protocols disallow processing instructions.

   The [in-scope namespaces] and [namespace attributes] for
   <literalValue> and <restrictBy> element items are determined
   according to Section 5.9 6.10 of the specification for RXER [RXER].  The
   [in-scope namespaces] and [namespace attributes] for other element
   items in the translation are determined according to Section 5.3.2.1 6.2.2.1
   of the specification for RXER.

   The [namespace name] of any element item or attribute item generated
   by the translation from an ASN.1 specification has no value unless
   specified otherwise.  In those cases where the [namespace name] of an
   element item has a value, the [prefix] of the element item is
   determined according to Section 5.3.2.2 6.2.2.2 of the specification for
   RXER.  In those cases where the [namespace name] of an attribute item
   has a value, the [prefix] of the attribute item is determined
   according to Section 5.3.3.1 6.2.3.1 of the specification for RXER.

      Aside: Non-canonical RXER allows all valid namespace prefixes and
      all valid placements for their corresponding namespace declaration
      attributes.

   Whenever an element item is added to the [children] of an enclosing
   element item item, the enclosing element item becomes the [parent] of the
   element item.

   Whenever an attribute item is added to the [attributes] of an element
   item
   item, the element item becomes the [owner element] of the attribute
   item.  For each attribute item, the [specified] property is set to
   true, the [attribute type] has no value and the value of the
   [references] property is set to unknown.

3.1.  Annotations

   In a number of places, as indicated in subsequent sections, the
   translator is permitted to add an element item with the [local name]
   "annotation".  The corresponding ASN.1 type for the <annotation>
   element item is the Markup type [RXER], and the [children] and [attributes] of the <annotation>
   element item are at the discretion of the translator.

   Typical uses of the <annotation> element item would be to hold
   comments from the ASN.1 specification that are normative in nature,
   e.g., a comment in a user defined constraint, or to hold directives
   for an ASN.1 compiler.



Legg                      Expires 20 April 2007                 [Page 7]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006

   Free text or XML comments in an <annotation> element will be



Legg                      Expires 22 June 2007                  [Page 7]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   preserved in a Canonical RXER (CRXER) encoding, encoding [RXER] (because the
   corresponding ASN.1 type for the <annotation> element item is the
   Markup type [RXER]), while XML comments outside <annotation> elements
   will not be. be preserved.

   Vendors using the <annotation> element items to hold ASN.1 compiler
   directives (as attributes or child elements of the <annotation>
   element) are encouraged to SHOULD use element or attribute names that are qualified
   with a namespace name specific to the vendor.

4.  ModuleDefinition Translation

   The translation of a ModuleDefinition [X.680] (an ASN.1 module) is a
   document item.  The [document element] of the document item is an
   element item with the [local name] "module" and the [namespace name]
   "urn:ietf:params:xml:ns:asnx".
   "urn:ietf:params:xml:ns:asnx" (i.e., an <asnx:module> element item).
   The element item is typically the [document element] of a document
   item.

   An attribute item with the [local name] "format" and
   [normalized value] "1.0" MAY be added to the [attributes] of the
   [document element].
   <asnx:module> element item.

   An ASN.1 module has a schema identity URI if it contains a
   SCHEMA-IDENTITY encoding instruction, in which case the schema
   identity URI is the character string specified by the AnyURIValue of
   the SCHEMA-IDENTITY encoding instruction.

   If the ASN.1 module being translated has a schema identity URI, then
   an attribute item with the [local name] "schemaIdentity" SHALL be
   added to the [attributes] of the [document element] (i.e., the <asnx:module> element item). item.  The
   [normalized value] of this attribute item is the schema identity URI
   of the module.

   An ASN.1 module has a target namespace if it contains a
   TARGET-NAMESPACE encoding instruction, in which case

   If the target namespace is the character string specified by the AnyURIValue of the
   TARGET-NAMESPACE encoding instruction.

   If [RXEREI] for the ASN.1 module being translated has a target namespace, is not absent,
   then an attribute item with the [local name] "targetNamespace" SHALL
   be added to the [attributes] of the [document element]. <asnx:module> element item.  The
   [normalized value] of this attribute item is the target namespace of
   the module.

      Aside: An ASN.1 module has a target namespace if it contains a
      TARGET-NAMESPACE encoding instruction.

   If the ASN.1 module contains a TARGET-NAMESPACE encoding instruction
   that specifies a Prefix, then an attribute item with the [local name]
   "targetPrefix" SHALL be added to the [attributes] of the
   [document element].
   <asnx:module> element item.  The [normalized value] of this attribute
   item is the character string specified by the NCName value of NCNameValue in the
   Prefix.



Legg                      Expires 20 April 22 June 2007                  [Page 8]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   In examples in the remainder of this document the namespace prefix
   "tns:" is used to stand for the target namespace of the module being
   translated.

   An attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the [document element]. <asnx:module> element item.  The
   [normalized value] of this attribute item is the modulereference in
   the ModuleIdentifier in the ModuleDefinition.

   If the DefinitiveIdentifier in the ModuleIdentifier in the
   ModuleDefinition is not empty, then an attribute item with the
   [local name] "identifier" SHALL be added to the [attributes] of the
   [document element].
   <asnx:module> element item.  The [normalized value] of this attribute
   item is the RXER character data translation [RXER] of the
   DefinitiveIdentifier.

   If the TagDefault in the ModuleDefinition is empty, then an attribute
   item with the [local name] "tagDefault" and [normalized value]
   "explicit" SHALL be added to the [attributes] of the
   [document element]. <asnx:module>
   element item.

   If the TagDefault in the ModuleDefinition is not empty and the first
   keyword in the TagDefault is not "AUTOMATIC", then an attribute item
   with the [local name] "tagDefault" SHALL be added to the [attributes]
   of the [document element]. <asnx:module> element item.  The [normalized value] of this
   attribute item is the first keyword in the TagDefault with all
   letters downcased, i.e., "explicit" or "implicit".

   If the TagDefault in the ModuleDefinition is not empty and the first
   keyword in the TagDefault is "AUTOMATIC", then an attribute item with
   the [local name] "tagDefault" and [normalized value] "automatic" MAY
   be added to the [attributes] of the [document element]. <asnx:module> element item.

   If the ExtensionDefault in the ModuleDefinition is not empty, then an
   attribute item with the [local name] "extensibilityImplied" and
   [normalized value] "true" or "1" SHALL be added to the [attributes]
   of the [document element]. <asnx:module> element item.

   If the ExtensionDefault in the ModuleDefinition is empty, then an
   attribute item with the [local name] "extensibilityImplied" and
   [normalized value] "false" or "0" MAY be added to the [attributes] of
   the [document element]. <asnx:module> element item.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the [document element]. <asnx:module> element item.

   The translation of each Assignment in the AssignmentList in the
   ModuleBody in the ModuleDefinition of the module being translated



Legg                      Expires 20 April 22 June 2007                  [Page 9]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   SHALL be appended to the [children] of the [document element]. <asnx:module> element
   item.

   If the EncodingControlSections instance in the ModuleDefinition
   contains an EncodingControlSection for RXER, then the translation of
   each NamedType in a TopLevelComponent [RXEREI] in a TopLevelComponents nested in the
   EncodingInstructionAssignmentList SHALL be added to the [children] of
   the [document element]. <asnx:module> element item.  The relative order of the top-level
   components [RXEREI] SHOULD be preserved in the translation, however
   the translations of the top-level components MAY be interspersed with
   the translations of the assignments in the AssignmentList.

   The translation of the EncodingControlSections instance in the
   ModuleDefinition of the module being translated SHALL be appended to
   the [children] of the [document element]. <asnx:module> element item.

   Example

      MyModule DEFINITIONS
      IMPLICIT TAGS
      EXTENSIBILITY IMPLIED ::=
      BEGIN

      MyType ::= INTEGER

      ENCODING-CONTROL RXER

          SCHEMA-IDENTITY  "http://example.com/id/MyModule"
          TARGET-NAMESPACE "http://example.com/ns/MyModule"

          COMPONENT myElement INTEGER

      END

      <asnx:module xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                   name="MyModule"
                   schemaIdentity="http://example.com/id/MyModule"
                   targetNamespace="http://example.com/ns/MyModule"
                   tagDefault="implicit"
                   extensibilityImplied="true">

       <namedType name="MyType" type="asnx:INTEGER"/>

       <element name="myElement" type="asnx:INTEGER"/>

      </asnx:module>

5.  Translation of Assignments



Legg                      Expires 20 April 22 June 2007                 [Page 10]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


5.1.  Referencing Named Constructs

   An Assignment in ASN.1 associates a reference name with a Type,
   Value, ValueSet, ObjectClass, Object or ObjectSet.  In  For ASN.X, the
   translation of the an
   Assignment is also regarded as associating a qualified an expanded name
   [XMLNS10][XMLNS11] with the Type, Value, ValueSet, ObjectClass,
   Object or ObjectSet.  ASN.X uses these expanded names, rendered as
   qualified names [XMLNS10][XMLNS11], in place of the references in an
   ASN.1 specification.

   In every case, the local part name of the qualified expanded name is the
   typereference, valuereference, objectclassreference, objectreference
   or objectsetreference in the Assignment (i.e., the [normalized value]
   of the name attribute item in the translation of the Assignment,
   ignoring white space characters).  If the target namespace of the
   ASN.1 module in which the Assignment is defined has a is not absent, then
   the namespace name of the expanded name is that target namespace, then this SHALL be
   otherwise the namespace name of the expanded name has no value.  When
   the expanded name is rendered as a qualified name.  The name, the namespace
   prefix is determined according to Section 5.6.11.1 6.7.11.1 of the
   specification for
   RXER.

   If the ASN.1 module in which the Assignment is defined does not have
   a target namespace, then the namespace name of the qualified name is
   absent (i.e., the name is unqualified). RXER [RXER].

   If an ASN.1 specification contains two or more modules without where the
   target
   namespaces, namespace is absent, then there exists the possibility that reference
   the expanded names defined in by the ASN.X translations of those modules
   are not distinct.  The reference expanded names are not distinct if if:

   (1) two or more type or value set assignments define the same typereference
       typereference, or

   (2) two or more value assignments define the same
   valuereference valuereference, or

   (3) two or more object class assignments define the same objectclassreference
       objectclassreference, or

   (4) two or more object assignments define the same objectreference objectreference,
       or

   (5) two or more object set assignments define the same objectsetreference
       objectsetreference, or

   (6) two or more top-level NamedType
   instances element components [RXEREI] subject to an ATTRIBUTE encoding instruction have the same effective name [RXEREI]
       local name, or

   (7) two or more top-level NamedType
   instances not subject to an ATTRIBUTE encoding instruction attribute components [RXEREI] have the same effective
       local name.

   If the reference expanded names are not distinct, then an unambiguous



Legg                      Expires 22 June 2007                 [Page 11]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   translation into ASN.X does not exist unless each of the modules has
   a SCHEMA-IDENTITY encoding instruction.  Consequently, if two or more
   modules without where the target namespaces namespace is absent are being translated
   into ASN.X and the reference names defined in those modules are will not
   be distinct, then as a local action prior to the translation, a
   SCHEMA-IDENTITY encoding instruction MUST be added to each of the
   modules that defines one or more of the indistinct
   reference expanded names and
   that does not already have a SCHEMA-IDENTITY encoding instruction.
   The character string (a URI) specified by the AnyURIValue of each
   added SCHEMA-IDENTITY encoding instruction is freely chosen by the
   translator, subject to the condition that these character strings are
   distinct [RXEREI].



Legg                      Expires 20 April 2007                [Page 11]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006

      Aside: Although this means that different translators might
      produce ASN.X documents modules that are syntactically different for any
      given ASN.1 module, those documents ASN.X modules will be semantically
      equivalent to each other and to the original ASN.1 module.

   TARGET-NAMESPACE and SCHEMA-IDENTITY encoding instructions are
   RECOMMENDED for every ASN.1 module.

5.2.  Importing Namespaces

   An Assignment is referenced from an ASN.X document module if its qualified associated
   expanded name appears as a qualified name in the [normalized value]
   of a an attribute item with the [local name] "type", "value", "class",
   "object" or "objectSet".  These references are categorized as direct
   references.  An Assignment or top-level component is also referenced
   from an ASN.X document module if its qualified expanded name appears as a qualified name
   in the [normalized value] of an attribute item with the [local name]
   "ref".  This reference is only categorized as direct if the ref
   attribute is not the result of the translation of a DefinedType
   subject to a TYPE-REF encoding instruction or a NamedType subject to
   an ATTRIBUTE-REF or ELEMENT-REF encoding instruction.

      Aside: In the case of an indirect reference, an attribute item
      with the [local name] "embedded" and [normalized value] "true" or
      "1" will also be present.

   Definition (external module): An external module is any module other
   than the module being translated and the AdditionalBasicDefinitions
   module [RXER].

      Aside: The AdditionalBasicDefinitions module is always assumed to
      be imported, as are all the built-in types and object classes of
      ASN.1.

   An element item with the [local name] "import" SHALL be added to the



Legg                      Expires 22 June 2007                 [Page 12]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   [children] of the [document element] <asnx:module> element item for each external module
   containing Assignments or top-level components that are directly
   referenced from the ASN.X document. module.  An <import> element item MAY be
   added to the [children] of the [document element] <asnx:module> element item for any
   other external module.

   An attribute item with the [local name] "name" SHOULD be added to the
   [attributes] of the <import> element item.  The [normalized value] of
   this attribute item is the modulereference in the ModuleIdentifier in
   the ModuleDefinition of the external module.

   If the DefinitiveIdentifier in the ModuleIdentifier in the
   ModuleDefinition of the external module is not empty, then an



Legg                      Expires 20 April 2007                [Page 12]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006
   attribute item with the [local name] "identifier" SHALL be added to
   the [attributes] of the <import> element item.  The
   [normalized value] of this attribute item is the RXER character data
   translation of the DefinitiveIdentifier.

   If the external module has a schema identity URI, then an attribute
   item with the [local name] "schemaIdentity" SHALL be added to the
   [attributes] of the <import> element item.  The [normalized value] of
   this attribute item is the schema identity URI of the external
   module.

   If the target namespace of the external module has a target namespace, is not absent, then an
   attribute item with the [local name] "namespace" SHALL be added to
   the [attributes] of the <import> element item.  The
   [normalized value] of this attribute item is the target namespace of
   the external module.

   An attribute item with the [local name] "schemaLocation" MAY be added
   to the [attributes] of the <import> element item.  The
   [normalized value] of this attribute item is a URI [URI] indicating
   the physical location of the ASN.X translation of the external
   module.

   The <import> element items MUST follow an <annotation> element item
   (if present) and MUST precede any other element items in the
   [children] of the [document element]. <asnx:module> element item.

   Note that because of the way parameterized references are expanded in
   ASN.X,
   ASN.X (see Section 13), the modules in the Imports of in the ModuleBody
   in the ModuleDefinition may not correspond exactly to the <import>
   element items.

5.3.  TypeAssignment Translation

   The translation of a TypeAssignment is an element item with the



Legg                      Expires 22 June 2007                 [Page 13]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   [local name] "namedType".  An attribute item with the [local name]
   "name" SHALL be added to the [attributes] of the <namedType> element
   item.  The [normalized value] of this attribute item is the
   typereference on the left hand side of the assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedType> element item.  The translation of
   the Type on the right hand side of the assignment SHALL be added to
   the [children] or [attributes] of the <namedType> element item.

   Example

      MyType ::= INTEGER

      <namedType name="MyType" type="asnx:INTEGER"/>



Legg                      Expires 20 April 2007                [Page 13]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006

5.4.  ValueAssignment and XMLValueAssignment Translation

   The translation of a ValueAssignment is an element item with the
   [local name] "namedValue".  An attribute item with the [local name]
   "name" SHALL be added to the [attributes] of the <namedValue> element
   item.  The [normalized value] of this attribute item is the
   valuereference on the left hand side of the assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedValue> element item.  The translation of
   the Type on the left hand side of the assignment and SHALL be added to
   the [children] or [attributes] of the <namedValue> element item.  The
   translation of the Value on the right hand side of the assignment
   SHALL be added to the [children] and/or or [attributes] of the <namedValue>
   element item.

   Example

      myValue INTEGER ::= 10

      <namedValue name="myValue" type="asnx:INTEGER" literalValue="10"/>

   An XMLValueAssignment is converted into the equivalent
   ValueAssignment and then translated as a ValueAssignment.  Note that
   the ASN.X representation for a Value is unrelated to XMLTypedValue.

5.5.  ValueSetTypeAssignment Translation

   The translation of a ValueSetTypeAssignment is an element item with
   the [local name] "namedValueSet".  An attribute item with the
   [local name] "name" SHALL be added to the [attributes] of the
   <namedValueSet> element item.  The [normalized value] of this



Legg                      Expires 22 June 2007                 [Page 14]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   attribute item is the typereference on the left hand side of the
   assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedValueSet> element item.  The translation
   of the Type on the left hand side of the assignment SHALL be added to
   the [children] or [attributes] of the <namedValueSet> element item.
   The translation of the ValueSet on the right hand side of the
   assignment SHALL be added to the [children] of the <namedValueSet>
   element item.

   Example

      MyValueSet INTEGER ::= { 10 }

      <namedValueSet name="MyValueSet" type="asnx:INTEGER">
       <valueSet>



Legg                      Expires 20 April 2007                [Page 14]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006
        <literalValue>10</literalValue>
       </valueSet>
      </namedValueSet>

5.6.  ObjectClassAssignment Translation

   The translation of an ObjectClassAssignment is an element item with
   the [local name] "namedClass".  An attribute item with the
   [local name] "name" SHALL be added to the [attributes] of the
   <namedClass> element item.  The [normalized value] of this attribute
   item is the objectclassreference on the left hand side of the
   assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedClass> element item.  The translation of
   the ObjectClass on the right hand side of the assignment SHALL be
   added to the [children] or [attributes] of the <namedClass> element
   item.

   Example

      MY-CLASS ::= TYPE-IDENTIFIER

      <namedClass name="MY-CLASS" class="asnx:TYPE-IDENTIFIER"/>

5.7.  ObjectAssignment Translation

   The translation of an ObjectAssignment is an element item with the
   [local name] "namedObject".  An attribute item with the [local name]
   "name" SHALL be added to the [attributes] of the <namedObject>
   element item.  The [normalized value] of this attribute item is the



Legg                      Expires 22 June 2007                 [Page 15]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   objectreference on the left hand side of the assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedObject> element item.  The translation of
   the DefinedObjectClass on the left hand side of the assignment and SHALL
   be added to the [children] or [attributes] of the <namedObject>
   element item.  The translation of the Object on the right hand side
   of the assignment SHALL be added to the [children] and/or or [attributes] of
   the <namedObject> element item.

   Example

      myObject TYPE-IDENTIFIER ::=
          { INTEGER NULL IDENTIFIED BY { 2 5 13 1 3 14 3 2 26 } }

      <namedObject name="myObject" class="asnx:TYPE-IDENTIFIER">
       <object>
        <field name="id" literalValue="2.5.13.14"/>



Legg                      Expires 20 April 2007                [Page 15]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006 literalValue="1.3.14.3.2.26"/>
        <field name="Type" type="asnx:INTEGER"/> type="asnx:NULL"/>
       </object>
      </namedObject>

5.8.  ObjectSetAssignment Translation

   The translation of an ObjectSetAssignment is an element item with the
   [local name] "namedObjectSet".  An attribute item with the
   [local name] "name" SHALL be added to the [attributes] of the
   <namedObjectSet> element item.  The [normalized value] of this
   attribute item is the objectsetreference on the left hand side of the
   assignment.

   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <namedObjectSet> element item.  The translation
   of the DefinedObjectClass on the left hand side of the assignment and
   SHALL be added to the [children] or [attributes] of the
   <namedObjectSet> element item.  The translation of the ObjectSet on
   the right hand side of the assignment SHALL be added to the
   [children] and/or or [attributes] of the <namedObjectSet> element item.

   Example

      MyObjectSet TYPE-IDENTIFIER ::= { myObject }

      <namedObjectSet name="MyObjectSet" class="asnx:TYPE-IDENTIFIER">
       <objectSet>
        <object ref="tns:myObject"/>
       </objectSet>
      </namedObjectSet>



Legg                      Expires 22 June 2007                 [Page 16]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


5.9.  Parameterized Definitions  ParameterizedAssignment Translation

   The translation of an ASN.1 specification into ASN.X replaces any
   DummyReference [X.683] or
   reference to a parameterized definition [X.683] with the definition
   expanded in-line (except for a special
   case involving recursive parameterized types).  For example, a
   ParameterizedObject is replaced by the Object on the right hand side
   of the referenced ParameterizedObjectAssignment.  Consequently in-line.  Consequently, there is no direct translation for a
   ParameterizedAssignment, though its definition may come into play in
   the translation of references to the parameterized definition.

   The definition that substitutes (see
   Section 13).

6.  Translation of Types

   The rules for a DummyReference or parameterized
   reference (e.g., translating the Object different varieties of Type are
   detailed in this section.

   Note that substitutes for a
   ParameterizedObject) potentially comes from the notation of ASN.1 is ambiguous where a different module from Type is both
   prefixed [X.680-1] (e.g., tagged) and constrained.  For example, the reference.  Expanding
   notation "[0] INTEGER (0..10)" could be interpreted as either a DummyReference
   tagged ConstrainedType or parameterized reference
   in-line puts the substitute definition into a constrained TaggedType.  For the context purposes
   of the module
   containing the reference, which could therefore alter the



Legg                      Expires 20 April 2007                [Page 16]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   interpretation of translation into ASN.X, the substitute definition.

   A type definition constraint is potentially dependent on assumed to have
   higher precedence than the TagDefault and
   ExtensionDefault of prefix, so the module in which it appears, and may also above notation would be
   affected by
   taken to be a tagged ConstrainedType.

6.1.  Identifier Replacement

   Various RXER encoding instructions can be used to override an
   identifier in an XML Encoding Rules (XER)
   [X.693] encoding control section [X.693-1].  Other kinds of
   definitions are not dependent on the module context, however type
   definitions can be nested within the other kinds of definitions, so a
   change of context can still be significant.

      Aside: Type definitions are not dependent on their module's RXER
      or Generic String Encoding Rules (GSER) [GSER] encoding control
      section [RXEREI][GSEREI] (as they are currently defined), so the
      presence of ASN.1 specification with an encoding control section for RXER or GSER is not
      significant in a change of context. NCName [XMLNS10].  The remainder of this section describes how and when a change of
   context
   NCName is indicated given pre-eminence in the ASN.X translation of a DummyReference or
   parameterized reference.

   In any instance of use, the module containing the DummyReference or
   parameterized reference is the referencing module and the module
   providing the substitute definition is the referenced module.  The
   referenced representation and referencing modules may be the same module.

   In the case of a ParameterizedType, the substitute definition
   identifier is the
   Type on the right hand side of the referenced
   ParameterizedTypeAssignment.

   In the case of a ParameterizedValueSetType, the substitute definition not explicitly given if it is the constrained type on the right hand side of the notional
   ParameterizedTypeAssignment equivalent algorithmically related
   to the referenced
   ParameterizedValueSetTypeAssignment (see Clause 15.8 of X.680
   [X.680]).

   In the case NCName.  The cases where an NCName overrides an identifier are
   covered individually in other parts of a ParameterizedValue, the substitute definition is the
   Value on the right hand side this specification and make
   use of the referenced
   ParameterizedValueAssignment.

   In the case following definition.

   Definition (reduction): The reduction of a ParameterizedObjectClass, the substitute definition an NCName is the ObjectClass on the right hand side of the referenced
   ParameterizedObjectClassAssignment.

   In the case string of a ParameterizedObject, the substitute definition is
   characters resulting from the Object following operations performed in order
   on the right hand side of the referenced
   ParameterizedObjectAssignment.

   In the case NCName:

   (1) replace each full stop ('.', U+002E) and low line ('_', U+005F)
       character with a hyphen character ('-', U+002D),

   (2) remove every character except latin letters (U+0041-U+005A,
       U+0061-U+007A), decimal digits (U+0030-U+0039) and hyphens
       (U+002D),

   (3) remove leading and trailing hyphen characters,

   (4) replace sequences of two or more hyphen characters with a ParameterizedObjectSet, the substitute definition is single
       hyphen, and




Legg                      Expires 20 April 22 June 2007                 [Page 17]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   (5) convert the ObjectSet on first character to lowercase if it is an uppercase
       letter.

      Aside: If the right hand side reduction of an NCName is not the referenced
   ParameterizedObjectSetAssignment.

   If same as the ActualParameter corresponding to
      identifier that the NCName replaces, then the identifier will be
      explicitly given in the translation into ASN.X.

6.2.  DefinedType Translation

   If a DummyReference Type is not a
   ValueSet, DefinedType in a ReferencedType, then the substitute definition for that DummyReference is translation
   of the Type, Value, DefinedObjectClass, Object or ObjectSet in Type is the
   ActualParameter corresponding to translation of the DummyReference. DefinedType.

   If the ActualParameter corresponding to a DummyReference DefinedType is not a
   ValueSet, then the substitute definition for that ParameterizedType,
   ParameterizedValueSetType or DummyReference and is
   the notional constrained type equivalent not subject to a
   TYPE-REF or REF-AS-TYPE encoding instruction, then the ValueSet; the
   ElementSetSpecs translation of
   the ValueSet contributes to DefinedType is either the constraint attribute form translation of the
   constrained a type and
   reference, or the governor element form translation of the Parameter corresponding to
   the ActualParameter is used as the parent a type that is constrained.

   Definition (interchangeable): reference.

   The contexts attribute form translation of the referencing and
   referenced modules are interchangeable a type reference is an attribute
   item with respect to interpreting the substitute definition if:

   (a) [local name] "type".  The [normalized value] of this
   attribute item is a qualified name for the expanded name of the
   referenced module type definition (see Section 5.1).  The attribute form
   translation SHALL NOT be used if this expanded name is the referencing module and does not
       contain an XER encoding control section, or

   (b) distinct
   with respect to the referenced current module and referencing module have the same
       TagDefault (where an absent TagDefault modules referenced by its
   <import> element items (see Section 5.1).

   The element form translation of a type reference is taken to an element item
   with the [local name] "type".  An element item with the [local name]
   "annotation" MAY be equivalent added to "EXPLICIT TAGS"), the referenced module and referencing module
       have [children] of the same ExtensionDefault, and neither module has an XER
       encoding control section.

      Aside: A module <type> element
   item.  An attribute item with an XER encoding control section is not
      considered the [local name] "ref" SHALL be added
   to have a context interchangeable with another module,
      including itself, because the typereference by which a substitute
      type definition [attributes] of the <type> element item.  The
   [normalized value] of this attribute item is identified may appear in a TargetList in qualified name for the
      XER encoding control section
   expanded name of the referenced module, type definition.  If this expanded
   name is not distinct with respect to the current module and because the in-line expansion of a substitute definition may cause
   modules referenced by its
      text <import> element items, then an attribute
   item with the [local name] "context" SHALL be added to come within the scope
   [attributes] of a TargetList in the XER encoding
      control section of <type> element item, otherwise if the referencing module that would not apply
      otherwise.

   Definition (recursively contained): A ParameterizedType is
   recursively contained if its translation will
   containing the referenced type definition has a schema identity URI,
   then an attribute item with the [local name] "context" MAY be nested within added
   to the
   translation (i.e., in-line expansion) [attributes] of another ParameterizedType to
   which it is equivalent.  A ParameterizedValueSetType is recursively
   contained if its translation will be nested within the translation <type> element item.  The
   [normalized value] of
   another ParameterizedValueSetType to which it this attribute item is equivalent.

      Aside: ASN.1 does not permit the other kinds schema identity URI
   of parameterized the module containing the type definition referenced by the
   DefinedType.

      Aside: If a reference to be recursive. name is not distinct, then the module
      containing the referenced definition must have a schema identity
      URI (see Section 5.1).




Legg                      Expires 20 April 22 June 2007                 [Page 18]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   An attribute item with the [local name] "embedded" and
   [normalized value] "false" or "0" MAY be added to the [attributes] of
   the <type> element item.

   The translation of a DummyReference, a ParameterizedType that the DefinedType is not
   recursively contained, a ParameterizedValue, a
   ParameterizedValueSetType that the same whether the type
   definition is not recursively contained, a
   ParameterizedObjectClass, referenced by a ParameterizedObject typereference or an
   ExternalTypeReference.

   If a
   ParameterizedObjectSet DefinedType is either:

   (1) subject to a TYPE-REF encoding instruction, then
   the translation of the substitute definition, or

   (2) DefinedType is an element item with the
   [local name] "type" if "type".  An element item with the substitute
       definition is a Type, "value" if [local name]
   "annotation" MAY be added to the substitute definition is a
       Value, "class" if [children] of the substitute definition is an ObjectClass or
       DefinedObjectClass, "object" if the substitute definition is an
       Object, or "objectSet" if <type> element
   item.  An attribute item with the substitute definition is an
       ObjectSet.  A fully expanded reference (described shortly) [local name] "ref" SHALL be added
   to the [children] [attributes] of the <type> element item.  The translation in case (2) is always allowed and provides
   information to identify the referenced module and the referenced
   definition.

   The translation in case (1) MAY be used instead if and only if the
   contexts of the referencing and referenced modules are
   interchangeable, or the contexts
   [normalized value] of the referencing and referenced
   modules are not interchangeable but the difference between them does
   not affect how the substitute definition this attribute item is interpreted.

      Aside: There are many ways in which the substitute definition can
      be unaffected by a difference between the contexts RXER character data
   translation of the
      referencing and referenced modules.  One example would be where
      the referencing and referenced modules differ only in their
      TagDefault, but the substitute definition does not contain any
      TaggedType notation.

   Note that if the translation QNameValue in case (1) is used, then the
   referencing module is still the referencing module when considering a
   nested in-line expansion. TYPE-REF encoding instruction.
   If the translation in case (2) is used,
   then the referenced module becomes the referencing module when
   considering a nested in-line expansion.

   A fully expanded reference ContextParameter is an element item with the [local name]
   "expanded".  Except present in the case of a DummyReference, RefParameters in the reference
   name is indicated by TYPE-REF
   encoding instruction, then an attribute item with the [local name] "name"
   "context" SHALL be added to the [attributes] of the <expanded> <type> element
   item.

   In the case of a ParameterizedType or ParameterizedValueSetType, the  The [normalized value] of this attribute item is the typereference string
   value of the
   ParameterizedType or ParameterizedValueSetType.




Legg                      Expires 20 April 2007                [Page 19]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   In AnyURIValue in the case of a ParameterizedValue, ContextParameter.  An attribute item
   with the [local name] "embedded" and [normalized value] "true" or "1"
   SHALL be added to the [attributes] of this the <type> element item.

      Aside: The embedded attribute item indicates whether a type is the valuereference of the ParameterizedValue.

   In the case of
      directly referenced as a ParameterizedObjectClass, DefinedType or indirectly referenced
      through a TYPE-REF encoding instruction.  An ASN.1 type can be
      referenced either way.  Type definitions in other schema languages
      cannot be directly referenced.

   If a DefinedType is subject to a REF-AS-TYPE encoding instruction,
   then the [normalized value] translation of
   this attribute item the DefinedType is an element item with the objectclassreference of
   [local name] "type".  An element item with the
   ParameterizedObjectClass,

   In [local name]
   "annotation" MAY be added to the case [children] of a ParameterizedObject, the [normalized value] of this <type> element
   item.  An attribute item is the objectreference of with the ParameterizedObject.

   In [local name] "elementType" SHALL be
   added to the case [attributes] of a ParameterizedObjectSet, the <type> element item.  The
   [normalized value] of this attribute item is the objectsetreference of the
   ParameterizedObjectSet.

   The "name" attribute item MAY be omitted if:

   (a) the conditions permitting the use RXER character data
   translation of the translation NameValue in the
       aforementioned case (1) are satisfied, or

   (b) the reference is not REF-AS-TYPE encoding instruction.
   If a typereference, or

   (c) the reference ContextParameter is a typereference that does not appear in any
       TargetList present in an XER encoding control section of the referenced
       module.

   The "name" attribute SHALL NOT appear RefParameters in the translation of a
   DummyReference.

   The referenced module is indicated by
   REF-AS-TYPE encoding instruction, then an element attribute item with the
   [local name] "module" "context" SHALL be added to the [children] [attributes] of the <expanded>
   <type> element item.  The <module> element [normalized value] of this attribute item MAY be omitted if the
   conditions permitting
   is the use string value of the translation AnyURIValue in the
   aforementioned case (1) are satisfied, ContextParameter.

   Example

      CHOICE {
          one    Foo,



Legg                      Expires 22 June 2007                 [Page 19]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


          two    [RXER:TYPE-REF
                     { namespace-name "http://www.example.com/PO1",
                       local-name "PurchaseOrderType" }]
                 Markup,
          three  [RXER:REF-AS-TYPE "product"
                     CONTEXT "http://www.example.com/inventory"]
                 Markup
      }

      <type>
       <choice>
        <element name="one" type="tns:Foo"/>
        <element name="two" xmlns:po="http://www.example.com/PO1">
         <type ref="po:PurchaseOrderType" embedded="true"/>
        </element>
        <element name="three">
         <type elementType="product"
               context="http://www.example.com/inventory"/>
        </element>
       </choice>
      </type>

   If a DefinedType is a DummyReference, ParameterizedType or if
   ParameterizedValueSetType, then the referencing module translation of the Type is the referenced module.  When
   translation of that DummyReference, ParameterizedType or
   ParameterizedValueSetType (see Section 13).

6.3.  Translation of Built-in Types

   If a Type is a BuiltinType or ReferencedType that is one of the <module>
   productions in Table 1 in Section 5 of the specification for RXER
   [RXER], then the translation of the Type is either the attribute form
   or element item form translation of that type.

   The attribute form translation of a Type that is present:

   (a) An a BuiltinType or
   ReferencedType that is one of the productions in Table 1 is an
   attribute item with the [local name] "name" SHOULD be added to
       the [attributes] of the <module> element item. "type".  The [normalized value]
   of this attribute item is a qualified name for the modulereference
       in the ModuleIdentifier in expanded name of
   the ModuleDefinition built-in type (see Section 5 of the referenced
       module.

   (b) If specification for RXER
   [RXER]).

   The element form translation of a Type that is a BuiltinType or
   ReferencedType that is one of the DefinitiveIdentifier productions in Table 1 is an
   element item with the ModuleIdentifier in [local name] "type".  An element item with the
       ModuleDefinition
   [local name] "annotation" MAY be added to the [children] of the referenced module is not empty, then an
   <type> element item.  An attribute item with the [local name] "identifier" "ref"
   SHALL be added to the [attributes] of the <module> <type> element item.  The
   [normalized value] of this attribute item is a qualified name for the RXER character
       data translation of the DefinitiveIdentifier.



Legg                      Expires 20 April 22 June 2007                 [Page 20]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   (c) If


   expanded name of the referenced module has built-in type.

   Example

      BOOLEAN

      <type ref="asnx:BOOLEAN"/>

   Usually the translator is free to choose either the attribute form or
   element form translation for a schema identity URI, then an Type, however in some contexts
   attribute forms for a Type are explicitly disallowed.

6.4.  BitStringType Translation

   The translation of a BitStringType with a NamedBitList is an element
   item with the [local name] "schemaIdentity" SHALL "type".  An element item with the
   [local name] "annotation" MAY be added to the [attributes] [children] of the <module>
   <type> element item.  The
       [normalized value] of this attribute  An element item is with the schema identity
       URI of [local name]
   "namedBitList" SHALL be appended to the referenced module.

   At least one [children] of the attribute items specified in cases (a), (b) and
   (c) MUST appear <type>
   element item.  The translation of each NamedBit in the [attributes] NamedBitList
   SHALL be appended to the [children] of the <module> <namedBitList> element
   item.

   The translation of a NamedBit is an element item with the substitute definition
   [local name] "namedBit".  An attribute item with the [local name]
   "name" SHALL be added to the
   [children] or [attributes] of the <expanded> <namedBit> element
   item.

   Example

      Consider these module definitions:

         Templates
         DEFINITIONS
         AUTOMATIC TAGS ::=
         BEGIN

         CollectionOfThings { Thing } ::= SEQUENCE OF thing Thing

         END

         ProtocolDefinitions
         DEFINITIONS
         AUTOMATIC TAGS ::=
         BEGIN

         IMPORTS
             CollectionOfThings{}
                 FROM Templates
             ;

         CollectionOfIntegers ::= CollectionOfThings { INTEGER }

         END

      The Type on the right hand side of  If the TypeAssignment for
      CollectionOfIntegers is a ParameterizedType.  Thing BitStringType is subject to a
      DummyReference.

      Without using the translation in case (1), VALUES encoding
   instruction, then the translations of
      these modules are:

         <asnx:module name="Templates"/>




Legg                      Expires 20 April 2007                [Page 21]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


         <asnx:module xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                      name="ProtocolDefinitions">

          <namedType name="CollectionOfIntegers">
           <type>
            <expanded name="CollectionOfThings">
             <module name="Templates"/>
             <type>
              <sequenceOf>
               <element name="thing">
                <type>
                 <expanded>
                  <module name="ProtocolDefinitions"/>
                  <type ref="asnx:INTEGER"/>
                 </expanded>
                </type>
               </element>
              </sequenceOf>
             </type>
            </expanded>
           </type>
          </namedType>

         </asnx:module>

      The translation [normalized value] of this attribute item is
   the Templates module replacement name [RXEREI] for the identifier in the NamedBit,
   otherwise it is empty because the
      module contains only a parameterized assignment.

      Since identifier in the contexts of NamedBit.  If the Templates and ProtocolDefinitions
      modules are interchangeable, BitStringType
   is subject to a simpler translation VALUES encoding instruction and the reduction of the
      ProtocolDefinitions module is permitted:

         <asnx:module xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                      name="ProtocolDefinitions">

          <namedType name="CollectionOfIntegers">
           <type>
            <sequenceOf>
             <element name="thing" type="asnx:INTEGER"/>
            </sequenceOf>
           </type>
          </namedType>

         </asnx:module>

   If a ParameterizedType or ParameterizedValueSetType
   replacement name (see Section 6.1) is recursively
   contained, not the same as the identifier,
   then its translation is an attribute item with the [local name] "identifier" SHALL be
   added to the [attributes] of the <namedBit> element item, otherwise
   an attribute item with the [local name] "type". "identifier" MAY be added to
   the [attributes] of the <namedBit> element item.  The
   [normalized value] of this attribute item is the identifier in the
   NamedBit.  An attribute item with the [local name]



Legg                      Expires 20 April 2007                [Page 22]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   "ancestor" "bit" SHALL be
   added to the [attributes] of the <type> <namedBit> element item.  The
   [normalized value] of this attribute item is the decimal digit string representing
   representation of the integer value of one plus the number of
   intermediate enclosing <type> element items between or DefinedValue in
   the NamedBit.

   Examples

      BIT STRING { zero(0), one(1), two(2) }

      <type>
   element items resulting from the translations



Legg                      Expires 22 June 2007                 [Page 21]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


       <namedBitList>
        <namedBit name="zero" bit="0"/>
        <namedBit name="one" bit="1"/>
        <namedBit name="two" bit="2"/>
       </namedBitList>
      </type>

      [RXER:VALUES ALL CAPITALIZED, wednesday AS "Midweek"]
          BIT STRING {
              monday(0), tuesday(1), wednesday(2),
              thursday(3), friday(4)
          }

      <type>
       <namedBitList>
        <namedBit name="Monday" bit="0"/>
        <namedBit name="Tuesday" bit="1"/>
        <namedBit name="Midweek" identifier="wednesday" bit="2"/>
        <namedBit name="Thursday" bit="3"/>
        <namedBit name="Friday" bit="4"/>
       </namedBitList>
      </type>

6.5.  IntegerType Translation

   The translation of an IntegerType with a NamedNumberList is an
   element item with the two equivalent
   instances of ParameterizedType or ParameterizedValueSetType. [local name] "type".  An element item with the
   [local name] "annotation" MAY be added to the [children] of the
   <type> element item.

   A <type>  An element item with an ancestor attribute item is a reference the [local name]
   "namedNumberList" SHALL be appended to an ancestor the [children] of the <type>
   element item.  This form for  The translation of each NamedNumber in the
   NamedNumberList SHALL be appended to the [children] of the
   <namedNumberList> element item.

   The translation of a <type> NamedNumber is an element item SHOULD NOT with the
   [local name] "namedNumber".  An attribute item with the [local name]
   "name" SHALL be used in original specifications written in ASN.X.

      Aside: The form is only intended for added to the purpose [attributes] of handling
      recursive parameterized type definitions in an ASN.1 specification
      being translated into ASN.X.  Such definitions are
      self-referencing but have no obvious name.  It the <namedNumber>
   element item.  If the IntegerType is also not easy subject to
      construct a suitable VALUES encoding
   instruction, then the [normalized value] of this attribute item is
   the replacement name from [RXEREI] for the surrounding context because
      recursive parameterized types can be embedded identifier in other constructs,
      such as information objects, that are themselves unnamed.

   Example

      Consider these type definitions, assumed to be defined the NamedNumber,
   otherwise it is the identifier in the NamedNumber.  If the
   IntegerType is subject to a module
      that does not have an XER VALUES encoding control section:

         Tree { ValueType } ::= SEQUENCE {
             value          [0] ValueType,
             left-subtree   [1] Tree { ValueType } OPTIONAL,
             right-subtree  [2] Tree { ValueType } OPTIONAL
         }

         NumberTree ::= [APPLICATION 13] Tree { INTEGER }

      The assignment for "Tree" is not directly translated because it is
      a ParameterizedAssignment.  The translation for the "NumberTree"
      assignment, up to but not yet including instruction and the Type in
   reduction of the
      TaggedType, replacement name (see Section 6.1) is not the same
   as follows:

         <namedType name="NumberTree">
          <type>
           <tagged tagClass="application" number="13"/>
          </type>
         </namedType>

      The Type in the TaggedType is a ParameterizedType.  Since identifier, then an attribute item with the
      ParameterizedType is not recursively contained [local name]
   "identifier" SHALL be added to the translation [attributes] of the ParameterizedType, using <namedNumber>
   element item, otherwise an attribute item with the translation in case (1) above, [local name]
   "identifier" MAY be added to the [attributes] of the <namedNumber>
   element item.  The [normalized value] of this attribute item is the



Legg                      Expires 20 April 22 June 2007                 [Page 23] 22]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   identifier in the translation of NamedNumber.  An attribute item with the Type on
   [local name] "number" SHALL be added to the right hand side [attributes] of the
      referenced ParameterizedTypeAssignment, namely this type:

         SEQUENCE {
             value          [0] ValueType,
             left-subtree   [1] Tree { ValueType } OPTIONAL,
             right-subtree  [2] Tree { ValueType } OPTIONAL
         }

      ValueType is a DummyReference.
   <namedNumber> element item.  The translation [normalized value] of the actual
      parameter substitutes for the DummyReference.  In this case the
      actual parameter attribute
   item is the type INTEGER.

      The translation for digit string representation of the SEQUENCE type, up to integer value of the first component,
      is added to
   SignedNumber or DefinedValue in the <tagged> element:

         <namedType name="NumberTree">
          <type>
           <tagged tagClass="application" number="13">
            <type><!-- Tree { NamedNumber.

   Examples

      INTEGER { nothing(0), a-little(1), a-lot(100) } -->
             <sequence>
              <element name="value">

      <type>
                <tagged number="0">
                 <type ref="asnx:INTEGER"/><!-- ValueType -->
                </tagged>
               </type>
              </element>
             </sequence>
       <namedNumberList>
        <namedNumber name="nothing" number="0"/>
        <namedNumber name="a-little" number="1"/>
        <namedNumber name="a-lot" number="100"/>
       </namedNumberList>
      </type>
           </tagged>

      [RXER:VALUES ALL CAPITALIZED, very-high AS "DANGEROUS"]
          INTEGER { low(25), medium(50), high(75), very-high(100) }

      <type>
       <namedNumberList>
        <namedNumber name="Low" number="25"/>
        <namedNumber name="Medium" number="50"/>
        <namedNumber name="High" number="75"/>
        <namedNumber name="DANGEROUS" identifier="very-high"
                     number="100"/>
       </namedNumberList>
      </type>
         </namedType>

6.6.  EnumeratedType Translation

   The Type in the TaggedType for the second component is a
      ParameterizedType.  Since this ParameterizedType is recursively
      contained its translation of an EnumeratedType is a <type> an element item with the ancestor
      attribute.  The value
   [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the ancestor attribute is "2" because
      there is one intermediate <type> element (for a TaggedType).  Put
      another way,
   item.  An element item with the translations of [local name] "enumerated" SHALL be
   appended to the equivalent instances [children] of
      ParameterizedType are two the <type> steps apart. element item.  The
   translation of each EnumerationItem nested in the third component RootEnumeration in
   the Enumerations instance in the EnumeratedType SHALL be appended to
   the [children] of the SEQUENCE type
      follows <enumerated> element item.

   If an ellipsis ("...") is present in the same pattern as Enumerations instance, then
   an element item with the [local name] "extension" SHALL be appended
   to the [children] of the <enumerated> element item and the second component.  The completed
   translation of the ExceptionSpec (possibly empty) SHALL be added to
   the [children] of the <extension> element item.  If an
   AdditionalEnumeration is as follows:

         <namedType name="NumberTree">
          <type> present in the Enumerations instance, then



Legg                      Expires 20 April 22 June 2007                 [Page 24] 23]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


           <tagged tagClass="application" number="13">
            <type><!-- Tree { INTEGER } -->
             <sequence>
              <element name="value">
               <type>
                <tagged number="0">
                 <type ref="asnx:INTEGER"/><!-- ValueType -->
                </tagged>
               </type>
              </element>
              <optional>
               <element name="left-subtree">
                <type>
                 <tagged number="1">
                  <type ancestor="2"/><!-- Tree { ValueType } -->
                 </tagged>
                </type>
               </element>
              </optional>
              <optional>
               <element name="right-subtree">
                <type>
                 <tagged number="2">
                  <type ancestor="2"/><!-- Tree { ValueType } -->
                 </tagged>
                </type>
               </element>
              </optional>
             </sequence>
            </type>
           </tagged>
          </type>
         </namedType>

6.  Translation of Types

   The rules for translating


   the different varieties translation of Type are
   detailed each EnumerationItem nested in this section.

   Note that the notation of ASN.1 is ambiguous where a Type is both
   prefixed [X.680-1] (e.g., tagged) and constrained.  For example, the
   notation "[0] INTEGER (0..10)" could
   AdditionalEnumeration SHALL be interpreted either as a
   tagged ConstrainedType or a constrained TaggedType.  For appended to the purposes [children] of the
   <extension> element item.

   The translation into ASN.X the constraint is assumed to have
   higher precedence than the prefix, so the above notation would be
   taken to be a tagged ConstrainedType.

6.1.  Identifier Replacement



Legg                      Expires 20 April 2007                [Page 25]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   Various RXER encoding instructions can be used to override of an
   identifier in EnumerationItem is an ASN.1 specification element item with an NCName [XMLNS10].  The
   NCName is given pre-eminence in the ASN.X representation and
   [local name] "enumeration".

   If the
   identifier is not explicitly given if it EnumerationItem is algorithmically related
   to the NCName.  The cases where an NCName overrides an identifier are
   covered individually in other parts of this specification and make
   use of the following definition.

   Definition (reduction): The reduction of "identifier" form, then an NCName is the string of
   characters resulting from the following operations performed in order
   on the NCName:

   (1) replace each "." (U+002E) and "_" (U+005F) character with a "-"
       (U+002D) character,

   (2) remove every character except latin letters (U+0041-U+005A,
       U+0061-U+007A), decimal digits (U+0030-U+0039) and hyphens
       (U+002D),

   (3) remove leading and trailing hyphen characters,

   (4) replace sequences of two or more hyphen characters attribute
   item with a single
       hyphen, and

   (5) convert the first character [local name] "name" SHALL be added to lowercase if it is an uppercase
       letter.

      Aside: If the reduction [attributes]
   of an NCName is not the same as the
      identifier that the NCName replaces, then the identifier will be
      explicitly given in the translation into ASN.X.

6.2.  DefinedType Translation <enumeration> element item.  If a Type the EnumeratedType is subject
   to a DefinedType in a ReferencedType, VALUES encoding instruction, then the translation [normalized value] of the Type this
   attribute item is the translation of replacement name [RXEREI] for the DefinedType.

   If a DefinedType identifier,
   otherwise it is not a ParameterizedType,
   ParameterizedValueSetType or DummyReference and the identifier.  If the EnumeratedType is not subject to
   a
   TYPE-REF or REF-AS-TYPE VALUES encoding instruction, then instruction and the translation reduction of the DefinedType replacement
   name (see Section 6.1) is either not the same as the identifier, then an
   attribute form translation item with the [local name] "identifier" SHALL be added to
   the [attributes] of a type
   reference, or the <enumeration> element form translation of a type reference.

   The attribute form translation of a type reference is item, otherwise an
   attribute item with the [local name] "type". "identifier" MAY be added to the
   [attributes] of the <enumeration> element item.  The
   [normalized value] of this attribute item is the qualified name referencing identifier.

   If the type definition
   (see Section 5.1).  The EnumerationItem is of the "NamedNumber" form, then an
   attribute form translation item with the [local name] "name" SHALL NOT be used
   if added to the qualified name
   [attributes] of the <enumeration> element item.  If the
   EnumeratedType is shared by two or more type definitions in
   separate modules, i.e., is ambiguous.



Legg                      Expires 20 April 2007                [Page 26]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   The element form translation of a type reference is an element item
   with the [local name] "type".  An attribute item with the
   [local name] "ref" SHALL be added subject to a VALUES encoding instruction, then the [attributes] of the <type>
   element item.  The
   [normalized value] of this attribute item is the
   qualified replacement name referencing
   [RXEREI] for the type definition. identifier in the NamedNumber, otherwise it is the
   identifier in the NamedNumber.  If this reference the EnumeratedType is subject to a
   VALUES encoding instruction and the reduction of the replacement name
   is not distinct with respect to the current module and same as the
   modules referenced by its <import> element items (see Section 5.1), identifier, then an attribute item with the
   [local name] "context" "identifier" SHALL be added to the [attributes] of the <type>
   <enumeration> element item, otherwise if the
   module containing the referenced type definition has a schema
   identity URI, then an attribute item with the
   [local name] "context" "identifier" MAY be added to the [attributes] of the <type>
   <enumeration> element item.  The [normalized value] of this attribute
   item is the schema identity URI
   of the module containing the type definition referenced by the
   DefinedType.

      Aside: If a reference name is not distinct, then the module
      containing identifier in the referenced definition must have a schema identity
      URI (see Section 5.1). NamedNumber.  An element attribute item with
   the [local name] "annotation" MAY "number" SHALL be added to the [children] [attributes] of the <type>
   <enumeration> element item.

   An  The [normalized value] of this attribute
   item with is the [local name] "embedded" and
   [normalized value] "false" or "0" MAY be added to digit string representation of the [attributes] integer value of the
   SignedNumber or DefinedValue in the NamedNumber.

   Examples

      ENUMERATED { red(0), green(1), ..., blue(2) }

      <type> element item.
       <enumerated>
        <enumeration name="red" number="0"/>
        <enumeration name="green" number="1"/>



Legg                      Expires 22 June 2007                 [Page 24]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


        <extension>
         <enumeration name="blue" number="2"/>
        </extension>
       </enumerated>
      </type>

      [RXER:VALUES ALL CAPITALIZED, red AS "Crimson"]
          ENUMERATED { red, yellow, green, blue }

      <type>
       <enumerated>
        <enumeration name="Crimson" identifier="red"/>
        <enumeration name="Yellow"/>
        <enumeration name="Green"/>
        <enumeration name="Blue"/>
       </enumerated>
      </type>

6.7.  PrefixedType Translation

   The translation of a PrefixedType [X.680-1] that is a TaggedType is
   either the DefinedType short form translation (Section 6.7.1) or long form
   translation (Section 6.7.2) of the TaggedType.

      Aside: The short form translation is provided because TaggedType
      notation is heavily used in existing ASN.1 specifications.  The
      long form translation has the same whether structure as the type
   definition translation of
      an EncodingPrefixedType and can be simplified where there is referenced by a typereference or an
   ExternalTypeReference.
      series of nested PrefixedType instances.

   If a DefinedType PrefixedType is subject to a TYPE-REF encoding instruction, then an EncodingPrefixedType and the translation of
   EncodingReference is RXER, or the DefinedType EncodingReference is an element item with empty and the
   [local name] "type".  An attribute item with
   default encoding reference [X.680-1] for the [local name] "ref"
   SHALL be added to module is RXER, then the [attributes]
   translation of the <type> element item.  The
   [normalized value] of this attribute item PrefixedType is the RXER character data translation of the QNameValue from the TYPE-REF encoding instruction.
   If the ContextParameter is present in the RefParameters Type in the
   TYPE-REF
   EncodingPrefixedType.

      Aside: This is not suggesting that RXER encoding instruction, then instructions are
      ignored.  Encoding instructions for RXER are not explicitly
      represented in ASN.X, but rather affect how an attribute item with the
   [local name] "context" SHALL be added to the [attributes] of ASN.1 module is
      translated into an ASN.X module (since the
   <type> element item.  The [normalized value] content of this attribute item an ASN.X
      module is also the string RXER encoding of an abstract value of the AnyURIValue in the ContextParameter.  An
   attribute item with the [local name] "embedded" and
   [normalized value] "true" or "1" SHALL be added to the [attributes]
      ModuleDefinition ASN.1 type in Appendix A).  The individual
      effects of RXER encoding instructions on the <type> element item.

      Aside: The embedded attribute item indicates whether translation are
      addressed in other parts of this specification.  Encoding
      instructions for other encoding rules have explicit
      representations in ASN.X.

   If a type PrefixedType is
      directly referenced as a DefinedType or indirectly referenced an EncodingPrefixedType and the



Legg                      Expires 20 April 22 June 2007                 [Page 27] 25]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      through a TYPE-REF


   EncodingReference is not RXER, or the EncodingReference is empty and
   the default encoding instruction.  An ASN.1 type can be
      referenced either way.  Type definitions in other schema languages
      cannot be directly referenced.

   An reference for the module is not RXER, then the
   translation of the PrefixedType is an element item with the
   [local name] "annotation" MAY "prefixed".  The translation of the EncodingPrefix in
   the EncodingPrefixedType SHALL be added to the [children] of the <type>
   <prefixed> element item.

   If a DefinedType the EncodingReference of an EncodingPrefix is subject to a REF-AS-TYPE encoding instruction, not empty, then the
   translation of the DefinedType EncodingPrefix is an element item with the
   [local name] "type".  An attribute item with
   encodingreference in the EncodingReference as the [local name]
   "elementType" name].  The
   translation of the EncodingInstruction in the EncodingPrefix SHALL be
   added to the [attributes] [children] of the <type> this element item.  The [normalized value]

   If the EncodingReference of this attribute item an EncodingPrefix is empty, then the
   RXER character data
   translation of the NameValue from EncodingPrefix is an element item with the REF-AS-TYPE default
   encoding instruction.  If reference for the Namespace module as the [local name].  The
   translation of the EncodingInstruction in the EncodingPrefix SHALL be
   added to the [children] of this element item.

   The EncodingInstruction notation is present different for each set of
   encoding instructions, and their translations into ASN.X are
   specified in separate documents [GSEREIT][XEREIT].  At the REF-AS-TYPE time of
   writing, only three sets of encoding instruction, instructions have been defined
   (for RXER [RXEREI], GSER [GSEREI] and EXTENDED-XER [X.693-1]).

   If the child <type> element item of a <prefixed> element item has no
   attribute items and has a child <prefixed> element item, then that
   child <type> element item MAY be replaced by the [children] and
   [attributes] of the inner <prefixed> element item.  Note that the
   long form translation of a TaggedType is also eligible for this
   rewriting step.  This rewriting step MAY be applied to the result of
   a previous rewriting step if the necessary condition still holds.

   Example

      These three definitions are equivalent.

      [XER:ATTRIBUTE] [XER:USE-UNION] [GSER:CHOICE-OF-STRINGS] CHOICE {
          one  PrintableString,
          two  UTF8String
      }

      <type>
       <prefixed>
        <XER><attribute/></XER>
        <type>
         <prefixed>
          <XER><useUnion/></XER>



Legg                      Expires 22 June 2007                 [Page 26]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


          <type>
           <prefixed>
            <GSER><choiceOfStrings/></GSER>
            <type>
             <choice>
              <element name="one" type="asnx:PrintableString"/>
              <element name="two" type="asnx:UTF8String"/>
             </choice>
            </type>
           </prefixed>
          </type>
         </prefixed>
        </type>
       </prefixed>
      </type>

      <type>
       <prefixed>
        <XER><attribute/></XER>
        <XER><useUnion/></XER>
        <GSER><choiceOfStrings/></GSER>
        <type>
         <choice>
          <element name="one" type="asnx:PrintableString"/>
          <element name="two" type="asnx:UTF8String"/>
         </choice>
        </type>
       </prefixed>
      </type>

6.7.1.  Short Form TaggedType Translation

   The short form translation of a TaggedType is an attribute element item with
   the [local name]
   "namespace" SHALL "type".  An element item with the [local name]
   "annotation" MAY be added to the [attributes] [children] of the <type> element
   item.  The [normalized value] of this attribute  An element item is with the string
   value of [local name] "tagged" SHALL be
   appended to the AnyURIValue in [children] of the Namespace. <type> element item.

   If the ContextParameter
   is present Class in the RefParameters Tag in the REF-AS-TYPE encoding
   instruction, TaggedType is not empty, then an
   attribute item with the [local name] "context" "tagClass" SHALL be added to the
   [attributes] of the <type> <tagged> element item.  The [normalized value] of
   this attribute item is the string value Class of the
   AnyURIValue in the ContextParameter. Tag with all letters
   downcased, i.e., either "universal", "application" or "private".

   An element attribute item with the [local name] "annotation" MAY "number" SHALL be added to
   the [children] [attributes] of the
   <type> <tagged> element item.

   Example

      CHOICE {
          one    Foo,
          two    [RXER:TYPE-REF
                     { namespace-name "http://www.example.com/PO1",
                       local-name "PurchaseOrderType" }
                 ] Markup,
          three  [RXER:REF-AS-TYPE "product"
                     CONTEXT "http://www.example.com/inventory"
                 ] Markup
      }

      <type xmlns:po="http://www.example.com/PO1">
       <choice>
        <element name="one" type="tns:Foo"/>
        <element name="two" type="po:PurchaseOrderType"/>
        <element name="three">
         <type elementType="product"
               context="http://www.example.com/inventory"/>
        </element>
       </choice>  The
   [normalized value] of this attribute item is the digit string
   representation of the integer value of the number or DefinedValue in



Legg                      Expires 20 April 22 June 2007                 [Page 28] 27]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      </type>

   If a DefinedType is a DummyReference, ParameterizedType or
   ParameterizedValueSetType, then the translation of the Type is the
   translation of that DummyReference, ParameterizedType or
   ParameterizedValueSetType (see Section 5.9).

6.3.  Translation of Predefined Types

   If a Type is a BuiltinType or ReferencedType comprising one of


   the
   productions ClassNumber in Table 1, then the translation of Tag.

   If the Type Tag is either
   the attribute form or element form translation of that type.

   The attribute form translation of a Type comprising of one of immediately followed by the
   productions in Table 1 is "IMPLICIT" keyword, then an
   attribute item with the [local name]
   "type".  The "tagging" and [normalized value] of this attribute item is a qualified
   name with
   "implicit" SHALL be added to the namespace name "urn:ietf:params:xml:ns:asnx" and [attributes] of the
   local part as indicated in Table 1.

   Table 1: Reference Names for Predefined Types

      +------------------------------------+-------------------+
      | ASN.1 Production                   | local part        |
      +====================================+===================+
      | BitStringType                      |                   |
      |    without a NamedBitList          | BIT-STRING        |
      +------------------------------------+-------------------+
      | BooleanType                        | BOOLEAN           |
      | EmbeddedPDVType                    | EMBEDDED-PDV      |
      | ExternalType                       | EXTERNAL          |
      +------------------------------------+-------------------+
      | IntegerType                        |                   |
      |    without a NamedNumberList       | INTEGER           |
      +------------------------------------+-------------------+
      | NullType                           | NULL              |
      | ObjectIdentifierType               | OBJECT-IDENTIFIER |
      | OctetStringType                    | OCTET-STRING      |
      | RealType                           | REAL              |
      | RelativeOIDType                    | RELATIVE-OID      |
      +------------------------------------+-------------------+
      | CharacterStringType                |                   |
      |    RestrictedCharacterStringType   |                   |
      |       BMPString                    | BMPString         |
      |       GeneralString                | GeneralString     |
      |       GraphicString                | GraphicString     |
      |       IA5String                    | IA5String         |
      |       ISO646String                 | ISO646String      |
      |       NumericString                | NumericString     |



Legg                      Expires 20 April 2007                [Page 29]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


      |       PrintableString              | PrintableString   |
      |       TeletexString                | TeletexString     |
      |       T61String                    | T61String         |
      |       UniversalString              | UniversalString   |
      |       UTF8String                   | UTF8String        |
      |       VideotexString               | VideotexString    |
      |       VisibleString                | VisibleString     |
      +------------------------------------+-------------------+
      |    UnrestrictedCharacterStringType | CHARACTER-STRING  |
      +------------------------------------+-------------------+
      | UsefulType                         |                   |
      |    GeneralizedTime                 | GeneralizedTime   |
      |    UTCTime                         | UTCTime           |
      |    ObjectDescriptor                | ObjectDescriptor  |
      +------------------------------------+-------------------+

   The <tagged> element form translation of a Type comprising one of
   item.

   If the
   productions in Table 1 Tag is an element item with immediately followed by the [local name]
   "type".  An "EXPLICIT" keyword, then an
   attribute item with the [local name] "ref" "tagging" and [normalized value]
   "explicit" SHALL be added to the [attributes] of the <type> <tagged> element
   item.

   The
   [normalized value] translation of this attribute item is a qualified name with
   the namespace name "urn:ietf:params:xml:ns:asnx" and the local part
   as indicated Type in Table 1.  An element item with the [local name]
   "annotation" MAY TaggedType SHALL be added to the
   [children] or [attributes] of the <type> <tagged> element item.

   Example

   Examples

      [0] INTEGER

      <type>
       <tagged number="0" type="asnx:INTEGER"/>
      </type>

      [APPLICATION 10] IMPLICIT BOOLEAN

      <type ref="asnx:BOOLEAN"/>

   Usually the translator is free to choose either the attribute form or
   element form translation for a Type, however in some contexts
   attribute forms for a Type are explicitly disallowed.

6.4.  BitStringType

      <type>
       <tagged tagClass="application" number="10" tagging="implicit"
               type="asnx:BOOLEAN"/>
      </type>

6.7.2.  Long Form TaggedType Translation

   The long form translation of a BitStringType with a NamedBitList TaggedType is an element item with the
   [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the <type> element
   item.  An element item with the [local name]
   "namedBitList" "prefixed" SHALL be
   appended to the [children] of the <type> element item.  The
   translation of each NamedBit the Tag in the NamedBitList TaggedType SHALL be appended added to the
   [children] of the <namedBitList> <prefixed> element item.

   The translation of a NamedBit Tag is an element item with the



Legg                      Expires 20 April 2007                [Page 30]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006 [local name] "namedBit".  An attribute item with
   "TAG".

   If the [local name]
   "name" SHALL Class of the Tag is not empty, then an attribute item with the
   [local name] "tagClass" SHALL be added to the [attributes] of the <namedBit>
   <TAG> element item.  If the BitStringType is subject to a VALUES encoding
   instruction, then the  The [normalized value] of this attribute item is
   the replacement name [RXEREI] for the identifier of the NamedBit,
   otherwise it is the identifier of the NamedBit.  If the BitStringType
   is subject to a VALUES encoding instruction and the reduction Class of the
   replacement name (see Section 6.1) is not the same as the identifier,
   then an Tag with all letters downcased, i.e., either
   "universal", "application" or "private".



Legg                      Expires 22 June 2007                 [Page 28]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   An attribute item with the [local name] "identifier" "number" SHALL be added to
   the [attributes] of the <namedBit> <TAG> element item, otherwise item.  The [normalized value]
   of this attribute item is the digit string representation of the
   integer value of the number or DefinedValue in the ClassNumber in the
   Tag.

   If the Tag is immediately followed by the "IMPLICIT" keyword, then an
   attribute item with the [local name] "identifier" MAY "tagging" and [normalized value]
   "implicit" SHALL be added to the [attributes] of the <namedBit> <TAG> element
   item.  The
   [normalized value] of this attribute item is

   If the identifier of Tag is immediately followed by the
   NamedBit.  An "EXPLICIT" keyword, then an
   attribute item with the [local name] "bit" "tagging" and [normalized value]
   "explicit" SHALL be added to the [attributes] of the <namedBit> <TAG> element
   item.

   The
   [normalized value] translation of this attribute item is the digit string
   representation of Type in the integer value of TaggedType SHALL be added to the number
   [children] or DefinedValue [attributes] of the NamedBit. <prefixed> element item.

   Examples

      BIT STRING { zero(0), one(1), two(2) }

      [0] INTEGER

      <type>
       <namedBitList>
        <namedBit name="zero" bit="0"/>
        <namedBit name="one" bit="1"/>
        <namedBit name="two" bit="2"/>
       </namedBitList>
       <prefixed type="asnx:INTEGER">
        <TAG number="0"/>
       </prefixed>
      </type>

      [RXER:VALUES ALL CAPITALIZED, wednesday AS "Midweek"]
          BIT STRING {
              monday(0), tuesday(1), wednesday(2),
              thursday(3), friday(4)
          }

      [APPLICATION 10] IMPLICIT BOOLEAN

      <type>
       <namedBitList>
        <namedBit name="Monday" bit="0"/>
        <namedBit name="Tuesday" bit="1"/>
        <namedBit name="Midweek" identifier="wednesday" bit="2"/>
        <namedBit name="Thursday" bit="3"/>
        <namedBit name="Friday" bit="4"/>
       </namedBitList>
       <prefixed type="asnx:BOOLEAN">
        <TAG tagClass="application" number="10" tagging="implicit"/>
       </prefixed>
      </type>

6.5.  IntegerType

6.8.  SelectionType Translation



Legg                      Expires 20 April 2007                [Page 31]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006

   The translation of an IntegerType with a NamedNumberList SelectionType is an element item with the
   [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the <type> element
   item.  An element item with the [local name]
   "namedNumberList" "selection" SHALL be
   appended to the [children] of the <type> element item.

   The translation of each NamedNumber identifier in a SelectionType identifies a NamedType in the
   NamedNumberList SHALL be appended to the [children]
   definition of the
   <namedNumberList> element item. Type in the SelectionType.  The translation of a NamedNumber is that
   NamedType will be an element item with the [local name] "namedNumber". either



Legg                      Expires 22 June 2007                 [Page 29]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   "attribute", "element", "component", "group" or "member".  An
   attribute item with the same [local name]
   "name" as the translation of the
   NamedType SHALL be added to the [attributes] of the <namedNumber> <selection>
   element item.  If the IntegerType is subject to a VALUES encoding
   instruction, then the  The [normalized value] of this attribute item is
   the replacement a
   qualified name [RXEREI] for the identifier expanded name of the NamedNumber,
   otherwise it is the identifier NamedType [RXEREI].

   The translation of the NamedNumber.  If Type in the
   IntegerType is subject SelectionType SHALL be added to a VALUES encoding instruction and
   the
   reduction [children] or [attributes] of the replacement name (see Section 6.1) <selection> element item.

   Examples

      field1 < MyChoiceType

      <type>
       <selection element="field1" type="tns:MyChoiceType"/>
      </type>

      field2 < CHOICE {
          field2  [RXER:ATTRIBUTE][RXER:NAME AS "field-two"] INTEGER
      }

      <type>
       <selection attribute="field-two">
        <type>
         <choice>
          <attribute name="field-two" identifier="field2"
                     type="asnx:INTEGER"/>
         </choice>
        </type>
       </selection>
      </type>

6.9.  InstanceOfType Translation

   The translation of an InstanceOfType is not the same
   as the identifier, then an attribute element item with the
   [local name]
   "identifier" SHALL "type".  An element item with the [local name]
   "annotation" MAY be added to the [attributes] [children] of the <namedNumber> <type> element
   item.  An element item, otherwise an attribute item with the [local name]
   "identifier" MAY "instanceOf" SHALL be added
   appended to the [attributes] [children] of the <namedNumber> <type> element item.  The [normalized value]
   translation of this attribute item is the
   identifier of the NamedNumber.  An attribute item with DefinedObjectClass in the
   [local name] "number" InstanceOfType SHALL be
   added to the [children] or [attributes] of the
   <namedNumber> <instanceOf> element
   item.  The [normalized value] of this attribute
   item is the digit string representation of the integer value of the
   SignedNumber or DefinedValue of the NamedNumber.

   Examples

      INTEGER { nothing(0), a-little(1), a-lot(100) }

      <type>
       <namedNumberList>
        <namedNumber name="nothing" number="0"/>
        <namedNumber name="a-little" number="1"/>
        <namedNumber name="a-lot" number="100"/>
       </namedNumberList>
      </type>

      [RXER:VALUES ALL CAPITALIZED, very-high AS "DANGEROUS"]
          INTEGER { low(25), medium(50), high(75), very-high(100) }

   Example

      INSTANCE OF TYPE-IDENTIFIER

      <type>
       <namedNumberList>
        <namedNumber name="Low" number="25"/>
        <namedNumber name="Medium" number="50"/>



Legg                      Expires 20 April 22 June 2007                 [Page 32] 30]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


        <namedNumber name="High" number="75"/>
        <namedNumber name="DANGEROUS" identifier="very-high"
                     number="100"/>
       </namedNumberList>


       <instanceOf class="asnx:TYPE-IDENTIFIER"/>
      </type>

6.6.  EnumeratedType

6.10.  ObjectClassFieldType Translation

   The translation of an EnumeratedType ObjectClassFieldType is an element item with
   the [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the <type> element
   item.  An element item with the [local name] "enumerated" "fromClass" SHALL be
   appended to the [children] of the <type> element item.  The
   translation of each EnumerationItem in the RootEnumeration SHALL be
   appended to the [children] of the <enumerated> element item.

   If the ellipsis ("...") is present, then an element item with the
   [local name] "extension" SHALL be appended to the [children] of the
   <enumerated> element item, and the translation of DefinedObjectClass in the ExceptionSpec
   (possibly empty) ObjectClassFieldType
   SHALL be added to the [children] or [attributes] of the <extension> <fromClass>
   element item.  If an AdditionalEnumeration is present, then the  The translation of each EnumerationItem the FieldName (see Section 9.2.6)
   in the AdditionalEnumeration ObjectClassFieldType SHALL be appended added to the [children] or
   [attributes] of the <extension> <fromClass> element item.

   Example

      OPERATION.&Linked.&ArgumentType

      <type>
       <fromClass class="tns:OPERATION"
                  fieldName="Linked/ArgumentType"/>
      </type>

6.11.  TypeFromObject and ValueSetFromObjects Translation

   The translation of an EnumerationItem a TypeFromObject or ValueSetFromObjects is an
   element item with the [local name] "enumeration".

   If the EnumerationItem is of the "identifier" form, then an attribute "type".  An element item with the
   [local name] "name" SHALL "annotation" MAY be added to the [attributes] [children] of the <enumeration>
   <type> element item.  If the EnumeratedType is subject
   to a VALUES encoding instruction, then the [normalized value] of this
   attribute item is the replacement name [RXEREI] for the identifier,
   otherwise it is the identifier.  If the EnumeratedType is subject to
   a VALUES encoding instruction and the reduction of the replacement
   name (see Section 6.1) is not the same as the identifier, then an
   attribute  An element item with the [local name] "identifier"
   "fromObjects" SHALL be added appended to the [attributes] [children] of the <enumeration> <type>
   element item, otherwise an
   attribute item with item.

   The translation of the [local name] "identifier" MAY ReferencedObjects instance in the
   TypeFromObject or ValueSetFromObjects SHALL be added to the
   [children] or [attributes] of the <enumeration> <fromObjects> element item.

   The
   [normalized value] of this attribute item is the identifier.

   If the EnumerationItem is translation of the "NamedNumber" form, then an
   attribute item with FieldName in the [local name] "name" TypeFromObject or
   ValueSetFromObjects SHALL be added to the [children] or [attributes]
   of the <enumeration> <fromObjects> element item.  If the
   EnumeratedType is subject to a VALUES encoding instruction, then the
   [normalized value] of this attribute item is the replacement name
   [RXEREI] for the identifier of the NamedNumber, otherwise it is the
   identifier of the NamedNumber.  If the EnumeratedType is subject to a

   Example

      invertMatrix.&Errors.&errorCode

      <type>
       <fromObjects object="tns:invertMatrix"



Legg                      Expires 20 April 22 June 2007                 [Page 33] 31]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   VALUES encoding instruction and


                    fieldName="Errors/errorCode"/>
      </type>

6.12.  Translation of Combining Types

   This section details the reduction translation of the replacement name ASN.1 combining types:
   SET, SEQUENCE, CHOICE, SET OF and SEQUENCE OF.  The combining type
   definitions all make use of the NamedType notation.

6.12.1.  NamedType Translation

   A NamedType is translated in one of three ways depending on the
   context.  These are the normal translation, the member translation
   and the item translation.  These translations are not
   interchangeable.  One of the same three will be explicitly invoked as part
   of the identifier, then translation of an attribute enclosing combining type.

   The normal translation of a NamedType is an element item with the
   [local name] "identifier" SHALL be added determined as follows:

   (1) if the NamedType is subject to an ATTRIBUTE or ATTRIBUTE-REF
       encoding instruction, or subject to a COMPONENT-REF encoding
       instruction that references a top-level NamedType that is subject
       to an ATTRIBUTE encoding instruction, then the [attributes] [local name] is
       "attribute",

   (2) otherwise, if the NamedType is subject to a GROUP encoding
       instruction, then the [local name] is "group",

   (3) otherwise, if the NamedType is subject to a SIMPLE-CONTENT
       encoding instruction, then the [local name] is "simpleContent",

   (4) otherwise, the [local name] is "element" or "component"
       (translator's choice).

      Aside: The local names "element" and "component" are synonymous.
      The "component" alternative is offered for specifying applications
      that don't use RXER (except for the ASN.X specification itself, of
      course), where referring to parts of an encoding as elements would
      seem incongruous.

   The member translation of a NamedType is an element item with the
   <enumeration>
   [local name] "member".

   The item translation of a NamedType is an element item, otherwise item with the
   [local name] "item".

      Aside: A Namedtype for which the member or item translation is



Legg                      Expires 22 June 2007                 [Page 32]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


      invoked will never be subject to an attribute ATTRIBUTE, ATTRIBUTE-REF,
      COMPONENT-REF, GROUP, SIMPLE-CONTENT or TYPE-AS-VERSION encoding
      instruction.  These encoding instructions are also mutually
      exclusive [RXEREI].

   An element item with the [local name] "identifier" "annotation" MAY be added to
   the [attributes] [children] of the
   <enumeration> <attribute>, <element>, <component>, <group>,
   <item>, <member> or <simpleContent> element item.  The

   If a NamedType is subject to a TYPE-AS-VERSION encoding instruction,
   then an attribute item with the [local name] "typeAsVersion" and
   [normalized value] of this "true" or "1" SHALL be added to the <element> or
   <component> element item.  For the normal translation, if a NamedType
   is not subject to an ATTRIBUTE, ATTRIBUTE-REF, COMPONENT-REF, GROUP,
   SIMPLE-CONTENT or TYPE-AS-VERSION encoding instruction, then an
   attribute item is with the identifier of [local name] "typeAsVersion" and
   [normalized value] "false" or "0" MAY be added to the NamedNumber.  An <element> or
   <component> element item.

   For the normal, member and item translations, if a NamedType is not
   subject to an ATTRIBUTE-REF, COMPONENT-REF, ELEMENT-REF or
   REF-AS-ELEMENT encoding instruction, then an attribute item with the
   [local name] "number" "name" SHALL be added to the [attributes] of the
   <enumeration>
   <attribute>, <element>, <component>, <group>, <item>, <member> or
   <simpleContent> element item.  The [normalized value] of this
   attribute item is the digit string representation local name of the integer value expanded name of the
   SignedNumber
   NamedType [RXEREI].

      Aside: If there are no NAME, ATTRIBUTE-REF, COMPONENT_REF,
      ELEMENT-REF or DefinedValue REF-AS-ELEMENT encoding instructions, then the
      local name of the NamedNumber.

   Example

      ENUMERATED { red(0), green(1), ..., blue(2) }

      <type>
       <enumerated>
        <enumeration name="red" number="0"/>
        <enumeration name="green" number="1"/>
        <extension>
         <enumeration name="blue" number="2"/>
        </extension>
       </enumerated>
      </type>

      [RXER:VALUES ALL CAPITALIZED, red AS "Crimson"]
          ENUMERATED { red, yellow, green, blue }

      <type>
       <enumerated>
        <enumeration name="Crimson" identifier="red"/>
        <enumeration name="Yellow"/>
        <enumeration name="Green"/>
        <enumeration name="Blue"/>
       </enumerated>
      </type>

6.7.  PrefixedType Translation

   The translation expanded name of a PrefixedType [X.680-1] that is a TaggedType NamedType is
   either the short form translation (Section 6.7.1) or long form
   translation (Section 6.7.2) same as the
      identifier in the NamedType.

   If the reduction of the TaggedType.

      Aside: The short form translation is provided because TaggedType
      notation local name (an NCName) of the expanded name
   of a NamedType is heavily used in existing ASN.1 specifications.  The
      long form translation has not the same structure as the translation of identifier in the NamedType,
   then an EncodingPrefixedType and can attribute item with the [local name] "identifier" SHALL be simplified where there is a



Legg                      Expires 20 April 2007                [Page 34]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


      series
   added to the [attributes] of nested PrefixedType instances.

   If a PrefixedType is an EncodingPrefixedType and the
   EncodingReference is RXER, <attribute>, <element>, <component>,
   <group>, <item>, <member> or <simpleContent> element item, otherwise
   an attribute item with the EncodingReference is empty and the
   default encoding reference [X.680-1] for the module is RXER, then [local name] "identifier" MAY be added to
   the
   translation [attributes] of the PrefixedType is the translation aforementioned element item.  The
   [normalized value] of this attribute item is the Type identifier in the
   EncodingPrefixedType.
   NamedType.

      Aside: This The identifier attribute is not suggesting that RXER encoding instructions are
      ignored.  Encoding instructions for RXER are not explicitly
      represented in ASN.X, but rather affect how an ASN.1 specification
      is translated into contingent on there being a
      name attribute.  That is, an ASN.X document (since the content of element item can have an
      ASN.X document identifier
      attribute item without having a name attribute item.

   If a NamedType is also the RXER subject to a COMPONENT-REF encoding of instruction,



Legg                      Expires 22 June 2007                 [Page 33]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   then an abstract value of attribute item with the ModuleDefinition ASN.1 type in Appendix A).  The individual
      effects [local name] "ref" SHALL be added to
   the [attributes] of RXER encoding instructions on the translation are
      addressed in other parts <attribute>, <element> or <component> element
   item.  The [normalized value] of this specification.  Encoding
      instructions for other encoding rules have explicit
      representations in ASN.X.

   If a PrefixedType attribute item is an EncodingPrefixedType and a qualified
   name for the
   EncodingReference is not RXER, or expanded name of the EncodingReference is empty and top-level NamedType referenced by
   the default encoding reference for instruction.  If the module expanded name is not RXER, then distinct with
   respect to the
   translation of current module and the PrefixedType is an modules referenced by its
   <import> element items (see Section 5.1), then an attribute item with
   the [local name] "prefixed".  The translation "context" SHALL be added to the [attributes] of the EncodingPrefix in
   <attribute>, <element> or <component> element item, otherwise if the EncodingPrefixedType SHALL
   module containing the referenced top-level NamedType has a schema
   identity URI, then an attribute item with the [local name] "context"
   MAY be added to the [children] [attributes] of the
   <prefixed> <attribute>, <element> or
   <component> element item.

   If  The [normalized value] of this attribute
   item is the EncodingReference schema identity URI of the module containing the
   referenced top-level NamedType.

      Aside: If an EncodingPrefix expanded name is not empty, distinct, then the
   translation of module
      containing the EncodingPrefix referenced top-level NamedType must have a schema
      identity URI (see Section 5.1).

   If a NamedType is subject to a COMPONENT-REF encoding instruction,
   then an element attribute item with the
   encodingreference of the EncodingReference as the [local name].  The
   translation of the EncodingInstruction in the EncodingPrefix SHALL name] "embedded" and
   [normalized value] "false" or "0" MAY be added to the [children] [attributes] of this
   the <attribute>, <element> or <component> element item.

   If the EncodingReference of an EncodingPrefix a NamedType is empty, subject to an ATTRIBUTE-REF or ELEMENT-REF encoding
   instruction, then the
   translation of the EncodingPrefix is an element attribute item with the default
   encoding reference for [local name] "ref" SHALL
   be added to the module as [attributes] of the [local name]. <attribute>, <element> or
   <component> element item.  The [normalized value] of this attribute
   item is the RXER character data translation of the EncodingInstruction QNameValue in the EncodingPrefix
   encoding instruction.  An attribute item with the [local name]
   "embedded" and [normalized value] "true" or "1" SHALL be added to the [children]
   [attributes] of this the <attribute>, <element> or <component> element
   item.

   The EncodingInstruction notation

   If a NamedType is different for each set of
   encoding instructions, and their translations into ASN.X are
   specified in separate documents [GSEREIT][XEREIT].  At the time of
   writing, only three sets of encoding instructions have been defined
   (for RXER [RXEREI], GSER [GSEREI] and EXTENDED-XER [X.693-1]).

   If the child <type> element item of a <prefixed> element item has no
   attribute items and has subject to a child <prefixed> element item, REF-AS-ELEMENT encoding instruction,
   then that
   child <type> element an attribute item MAY with the [local name] "elementType" SHALL be replaced by
   added to the [children] and



Legg                      Expires 20 April 2007                [Page 35]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006 [attributes] of the inner <prefixed> <element> or <component> element
   item.  Note that the
   long form translation  The [normalized value] of a TaggedType is also eligible for this
   rewriting step.  This rewriting step MAY be applied to the result of
   a previous rewriting step if attribute item is the necessary condition still holds.

   Example

      These three definitions are equivalent.

      [XER:ATTRIBUTE] [XER:USE-UNION] [GSER:CHOICE-OF-STRINGS] CHOICE {
          one  PrintableString,
          two  UTF8String
      }

      <type>
       <prefixed>
        <XER><attribute/></XER>
        <type>
         <prefixed>
          <XER><useUnion/></XER>
          <type>
           <prefixed>
            <GSER><choiceOfStrings/></GSER>
            <type>
             <choice>
              <element name="one" type="asnx:PrintableString"/>
              <element name="two" type="asnx:UTF8String"/>
             </choice>
            </type>
           </prefixed>
          </type>
         </prefixed>
        </type>
       </prefixed>
      </type>

      <type>
       <prefixed>
        <XER><attribute/></XER>
        <XER><useUnion/></XER>
        <GSER><choiceOfStrings/></GSER>
        <choice>
         <element name="one" type="asnx:PrintableString"/>
         <element name="two" type="asnx:UTF8String"/>
        </choice>
       </prefixed>
      </type>




Legg                      Expires 20 April 2007                [Page 36]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


6.7.1.  Short Form TaggedType Translation

   The short form RXER
   character data translation of the NameValue in the REF-AS-ELEMENT
   encoding instruction.  If a TaggedType Namespace is an element item with present in the [local name] "type".  An element
   REF-AS-ELEMENT encoding instruction, then an attribute item with the
   [local name]
   "annotation" MAY "namespace" SHALL be added to the [children] [attributes] of the <type>
   <element> or <component> element item.  An element  The [normalized value] of
   this attribute item with the [local name] "tagged" SHALL be
   appended to is the [children] string value of the <type> element item.

   If AnyURIValue in the Class of
   Namespace.

   If a ContextParameter is present in the Tag RefParameters in the TaggedType is not empty,



Legg                      Expires 22 June 2007                 [Page 34]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   ATTRIBUTE-REF, ELEMENT-REF or REF-AS-ELEMENT encoding instruction,
   then an attribute item with the [local name] "tagClass" "context" SHALL be added
   to the [attributes] of the <tagged> <attribute>, <element> or <component>
   element item.  The [normalized value] of this attribute item is the Class
   string value of the Tag, with all letters
   downcased, i.e., either "universal", "application" or "private".

   If AnyURIValue in the Tag ContextParameter.

   If a NamedType is immediately followed by the "IMPLICIT" keyword, subject to both an ATTRIBUTE encoding instruction
   and a VERSION-INDICATOR encoding instruction, then an attribute item
   with the [local name] "tagging" "versionIndicator" and [normalized value]
   "implicit"
   "true" or "1" SHALL be added to the [attributes] of the <tagged> <attribute> element item.  If the Tag a
   NamedType is immediately followed by the "EXPLICIT" keyword, subject to an ATTRIBUTE encoding instruction and not
   subject to a VERSION-INDICATOR encoding instruction, then an
   attribute item with the [local name] "tagging" "versionIndicator" and
   [normalized value]
   "explicit" SHALL "false" or "0" MAY be added to the [attributes] of the <tagged> <attribute>
   element item.

   If the Tag a NamedType is not immediately followed by either the "IMPLICIT" subject to an ATTRIBUTE-REF, COMPONENT-REF,
   ELEMENT-REF or
   "EXPLICIT" keyword and REF-AS-ELEMENT encoding instruction, then the
   translation of the Type in the TaggedType is a
   DummyReference, then an attribute item with the [local name]
   "tagging" and [normalized value] "explicit" NamedType SHALL be added to the
   [children] or [attributes] of the <tagged> <attribute>, <element>,
   <component>, <group>, <item>, <member> or <simpleContent> element
   item.

   The

   If a NamedType is subject to an ATTRIBUTE-REF, COMPONENT-REF,
   ELEMENT-REF or REF-AS-ELEMENT encoding instruction, then the
   translation of each EncodingPrefix (Section 6.7) and Tag
   (Section 6.7.2) textually within the Type in the TaggedType NamedType SHALL be added in
   order to the [children] or [attributes] of the <tagged> <attribute>, <element> or <component>
   element item.

   Examples

      [0] INTEGER

      <type>
       <tagged number="0" type="asnx:INTEGER"/>
      </type>

      [APPLICATION 10] IMPLICIT BOOLEAN

      <type>
       <tagged tagClass="application" number="10" tagging="implicit"
               type="asnx:BOOLEAN"/>
      </type>

   Example

      CHOICE {
          one    INTEGER,
          two    [RXER:ATTRIBUTE] BOOLEAN,
          three  [RXER:ATTRIBUTE-REF
                     { namespace-name "http://www.example.com/schema",
                       local-name "foo" }]
                 UTF8String,
          bar    [RXER:ELEMENT-REF
                     { namespace-name "http://www.example.com/schema",
                       local-name "bar" }]
                 Markup,
          five   [0] [RXER:REF-AS-ELEMENT "product"
                     CONTEXT "http://www.example.com/inventory"]
                 Markup,
          six    [RXER:GROUP] MySequence
      }



Legg                      Expires 20 April 22 June 2007                 [Page 37] 35]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


6.7.2.  Long Form TaggedType


      <type>
       <choice xmlns:ex="http://www.example.com/schema">
        <element name="one" type="asnx:INTEGER"/>
        <attribute name="two" type="asnx:BOOLEAN"/>
        <attribute ref="ex:foo" identifier="three" embedded="true"/>
        <element ref="ex:bar" embedded="true"/>
        <element elementType="product"
                 context="http://www.example.com/inventory"
                 identifier="five">
         <TAG number="0"/>
        </element>
        <group name="six" type="tns:MySequence"/>
       </choice>
      </type>

6.12.2.  SequenceType Translation

   The long form translation of a TaggedType SequenceType is an element item with the
   [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the <type> element
   item.  An element item with the [local name] "prefixed" "sequence" SHALL be
   appended to the [children] of the <type> element item.  The
   translation of each ComponentType nested in the Tag ComponentTypeList in
   the TaggedType initial RootComponentTypeList, if present, SHALL be added appended to
   the [children] of the <prefixed> <sequence> element item.

   The translation of a Tag

   If an ExtensionAndException is present, then an element item with the
   [local name]
   "TAG".

   If "extension" SHALL be appended to the Class [children] of the Tag
   <sequence> element item.  If an ExceptionSpec is not empty, present in the
   ExtensionAndException, then an attribute item with the
   [local name] "tagClass" translation of the ExceptionSpec
   (possibly empty) SHALL be added to the [attributes] [children] of the
   <TAG> <extension>
   element item.  The [normalized value] of this attribute item

   If an ExtensionAdditions instance is present, then the Class translation of the Tag, with all letters downcased, i.e., either
   "universal", "application"
   each ExtensionAdditionGroup or "private".

   If the Tag is immediately followed by the "IMPLICIT" keyword, then an
   attribute item with ComponentType nested in the [local name] "tagging" and [normalized value]
   "implicit"
   ExtensionAdditions (if any) SHALL be added appended to the [attributes] [children] of
   the <TAG> <extension> element item.

   If the Tag an ExtensionEndMarker is immediately followed by the "EXPLICIT" keyword, present, then an
   attribute item with the [local name] "tagging" and [normalized value]
   "explicit" translation of each
   ComponentType nested in the ComponentTypeList in the final
   RootComponentTypeList SHALL be added appended to the [attributes] [children] of the <TAG>
   <sequence> element item.

   If the Tag

   The translation of an ExtensionAdditionGroup is not immediately followed by either an element item with
   the "IMPLICIT" or
   "EXPLICIT" keyword and [local name] "extensionGroup".  If the Type VersionNumber in the TaggedType
   ExtensionAdditionGroup is a
   DummyReference, not empty, then an attribute item with the
   [local name]
   "tagging" and [normalized value] "explicit" "version" SHALL be added to the [attributes] of the <TAG>
   <extensionGroup> element item.  The translation [normalized value] of this



Legg                      Expires 22 June 2007                 [Page 36]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   attribute item is the Type number in the TaggedType VersionNumber.  The translation
   of each ComponentType nested in the ExtensionAdditionGroup SHALL be added
   appended to the [children] or [attributes] of the <prefixed> <extensionGroup> element item.

   Examples

      [0] INTEGER

      <type>
       <prefixed type="asnx:INTEGER">
        <TAG number="0"/>
       </prefixed>
      </type>




Legg                      Expires 20 April 2007                [Page 38]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


      [APPLICATION 10] IMPLICIT BOOLEAN

      <type>
       <prefixed type="asnx:BOOLEAN">
        <TAG tagClass="application" number="10" tagging="implicit"/>
       </prefixed>
      </type>

6.8.  SelectionType Translation

   The translation of a SelectionType ComponentType of the "NamedType" form is the
   normal translation of the NamedType.

   The translation of a ComponentType of the "NamedType OPTIONAL" form
   is an element item with the [local name] "type".  An "optional".  The normal
   translation of the NamedType SHALL be added to the [children] of the
   <optional> element item.

   The translation of a ComponentType of the "NamedType DEFAULT Value"
   form is an element item with the [local name]
   "annotation" MAY "optional".  The normal
   translation of the NamedType SHALL be added to the [children] of the <type>
   <optional> element item.  An element item with the [local name] "selection"
   "default" SHALL be appended to the [children] of the <type> <optional>
   element item.  The identifier in a SelectionType identifies a NamedType in the
   definition translation of the Type in Value SHALL be added to the SelectionType.
   [children] or [attributes] of the <default> element item.

   The translation of that
   NamedType will be a ComponentType of the "COMPONENTS OF Type" form
   is an element item with the [local name] either
   "attribute", "element", "group" or "member".  An attribute item with
   the same [local name] as the "componentsOf".  The
   translation of the NamedType Type SHALL be added to the [children] or
   [attributes] of the <selection> element item.  The
   [normalized value] of this attribute item is the RXER character data
   translation of the effective name of the NamedType.

   The translation of the Type in the SelectionType SHALL be added to
   the [children] or [attributes] of the <selection> <componentsOf> element item.

   Example

      field1 < MyChoiceType

      <type>
       <selection element="field1" type="tns:MyChoiceType"/>
      </type>

      field2 < CHOICE

      SEQUENCE {
          field2  [RXER:ATTRIBUTE][RXER:NAME AS "field-two"] INTEGER
          one    INTEGER,
          two    [RXER:ATTRIBUTE] BOOLEAN OPTIONAL,
          ...,
          [[ 2:
              four   NULL
          ]],
          COMPONENTS OF MySequence,
          ...,
          three   PrintableString DEFAULT "third"
      }

      <type>
       <selection attribute="field-two">
        <type>
         <choice>
          <attribute name="field-two" identifier="field2"
       <sequence>
        <element name="one" type="asnx:INTEGER"/>
         </choice>
        </type>
        <optional>
         <attribute name="two" type="asnx:BOOLEAN"/>
        </optional>
        <extension>
         <extensionGroup version="2">
          <element name="four" type="asnx:NULL"/>



Legg                      Expires 20 April 22 June 2007                 [Page 39] 37]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


       </selection>


         </extensionGroup>
         <componentsOf type="tns:MySequence"/>
        </extension>
        <optional>
         <element name="three" type="asnx:PrintableString"/>
         <default literalValue="third"/>
        </optional>
       </sequence>
      </type>

6.9.  InstanceOfType

6.12.3.  SetType Translation

   The translation of an InstanceOfType a SetType follows the same procedure as the
   translation of a SequenceType except that SetType replaces
   SequenceType, "SET" replaces "SEQUENCE", and the [local name] "set"
   is used instead of "sequence".

6.12.4.  ChoiceType Translation

   The translation of a ChoiceType that is not subject to a UNION
   encoding instruction is an element item with the [local name] "type".
   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <type> element item.  An element item with the
   [local name] "instanceOf" "choice" SHALL be appended to the [children] of the
   <type> element item.  The normal translation of each NamedType nested
   in the DefinedObjectClass AlternativeTypeList in the InstanceOfType RootAlternativeTypeList in the
   AlternativeTypeLists SHALL be
   added appended to the [children] or [attributes] of the <instanceOf>
   <choice> element item.

   Example

      INSTANCE OF TYPE-IDENTIFIER

      <type>
       <instanceOf class="asnx:TYPE-IDENTIFIER"/>
      </type>

6.10.  ObjectClassFieldType Translation

   The translation of

   If an ObjectClassFieldType ExtensionAndException is an element item with present in the [local name] "type".  An AlternativeTypeLists,
   then an element item with the [local name]
   "annotation" MAY "extension" SHALL be added
   appended to the [children] of the <type> <choice> element item.  An element item with  If an
   ExceptionSpec is present in the [local name] "fromClass" SHALL be
   appended ExtensionAndException, then the
   translation of the ExceptionSpec (possibly empty) is added to the
   [children] of the <type> <extension> element item.  The
   translation of the DefinedObjectClass

   If an ExtensionAdditionAlternatives instance is present in the ObjectClassFieldType and
   AlternativeTypeLists, then the translation of the FieldName (see Section 9.2.6) each
   ExtensionAdditionAlternativesGroup or NamedType (if any) nested in
   the
   ObjectClassFieldType ExtensionAdditionAlternatives SHALL be added appended in order to the
   [children] and/or
   [attributes] of the <fromClass> <extension> element item.

   Example

      OPERATION.&Linked.&ArgumentType

      <type>
       <fromClass class="tns:OPERATION"
                  fieldName="Linked/ArgumentType"/>
      </type>

6.11.  TypeFromObject and ValueSetFromObjects Translation  The normal translation
   of a TypeFromObject or ValueSetFromObjects the NamedType is used.

   The translation of an ExtensionAdditionAlternativesGroup is an
   element item with the [local name] "type".  An element "extensionGroup".  If the
   VersionNumber in the ExtensionAdditionAlternativesGroup is not empty,
   then an attribute item with the [local name] "annotation" MAY "version" SHALL be added
   to the [children] [attributes] of the <extensionGroup> element item.  The



Legg                      Expires 20 April 22 June 2007                 [Page 40] 38]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   <type> element item.  An element


   [normalized value] of this attribute item with is the [local name]
   "fromObjects" number in the
   VersionNumber.  The normal translation of each NamedType nested in
   the AlternativeTypeList in the ExtensionAdditionAlternativesGroup
   SHALL be appended to the [children] of the <type> <extensionGroup> element
   item.

   Example

      CHOICE {
          one  INTEGER,
          two  [RXER:NAME AS "Two"] BOOLEAN,
          ...,
          [[ 2:
              three  NULL
          ]],
          four  PrintableString,
          ...
      }

      <type>
       <choice>
        <element name="one" type="asnx:INTEGER"/>
        <element name="Two" type="asnx:BOOLEAN"/>
        <extension>
         <extensionGroup version="2">
          <element name="three" type="asnx:NULL"/>
         </extensionGroup>
         <element name="four" type="asnx:PrintableString"/>
        </extension>
       </choice>
      </type>

6.12.5.  Translation of UNION Types

   The translation of a ChoiceType that is subject to a UNION encoding
   instruction follows the ReferencedObjects in same procedure as the TypeFromObject or
   ValueSetFromObjects SHALL be added translation of a
   ChoiceType that is not subject to a UNION encoding instruction except
   that the [children] or [attributes] [local name] "union" is used instead of "choice", and the <fromObjects> element item.

   The
   member translation of each NamedType is used instead of the FieldName in normal
   translation.

   In addition, if the TypeFromObject or
   ValueSetFromObjects UNION encoding instruction has a PrecedenceList,
   then an attribute item with the [local name] "precedence" SHALL be
   added to the [children] or [attributes] of the <fromObjects> <union> element item.

   Example

      invertMatrix.&Errors.&errorCode

      <type>
       <fromObjects object="tns:invertMatrix"
                    fieldName="Errors/errorCode"/>
      </type>

6.12.  Translation  The
   [normalized value] of Combining Types

   This section details this attribute item is the translation white space
   separated list of qualified names for the ASN.1 combining types:
   SET, SEQUENCE, CHOICE, SET OF and SEQUENCE OF.  The combining type
   definitions all make use expanded names of the
   NamedType notation.

6.12.1.  NamedType Translation instances [RXEREI] corresponding to the identifiers in the
   PrecedenceList.  A NamedType white space separator is translated in one of three ways depending on the
   context.  These are the normal translation, the member translation
   and the item translation.  These translations are not
   interchangeable.  One of the three will be explicitly invoked as part or more of the white



Legg                      Expires 22 June 2007                 [Page 39]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   space characters.

   Example

      [RXER:UNION PRECEDENCE utf8 visible] CHOICE {
          printable  PrintableString,
          teletex    TeletexString,
          visible    [RXER:NAME AS "ascii"] VisibleString,
          ...,
          utf8       UTF8String
      }

      <type>
       <union precedence="utf8 ascii">
        <member name="printable" type="asnx:PrintableString"/>
        <member name="teletex" type="asnx:TeletexString"/>
        <member name="ascii" identifier="visible"
                type="asnx:VisibleString"/>
        <extension>
         <member name="utf8" type="asnx:UTF8String"/>
        </extension>
       </union>
      </type>

6.12.6.  SequenceOfType Translation

   The translation of an enclosing combining type.

   If a NamedType SequenceOfType that is subject to an ATTRIBUTE or ATTRIBUTE-REF encoding
   instruction or not subject to a COMPONENT-REF LIST
   encoding instruction that
   references a top-level NamedType that is subject to an ATTRIBUTE
   encoding instruction, then element item with the normal translation [local name] "type".
   An element item with the [local name] "annotation" MAY be added to
   the [children] of the NamedType is
   an <type> element item.  An element item with the
   [local name] "attribute", otherwise if "sequenceOf" SHALL be appended to the
   NamedType [children] of the
   <type> element item.

   If the SequenceOfType is subject to a GROUP encoding instruction, of the "SEQUENCE OF NamedType" form, then
   the normal translation of the NamedType SHALL be added to the
   [children] of the <sequenceOf> element item.

   If the SequenceOfType is of the "SEQUENCE OF Type" form, then an
   element item with the [local name]
   "group", otherwise if the NamedType is subject "element" or "component"
   (translator's choice) SHALL be added to a SIMPLE-CONTENT
   encoding instruction, then the normal translation [children] of the NamedType is
   an
   <sequenceOf> element item.  An attribute item with the [local name] "simpleContent", otherwise
   "name" and [normalized value] "item" SHALL be added to the
   normal translation
   [attributes] of the NamedType is an <element> or <component> element item.  An
   attribute item with the [local name] "element" "identifier" and empty
   [normalized value] SHALL be added to the [attributes] of the
   <element> or "component" (translator's choice). <component> element item.  The translation of the Type
   SHALL be added to the [children] or [attributes] of the <element> or
   <component> element item.



Legg                      Expires 20 April 22 June 2007                 [Page 41] 40]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      Aside: The local names "element" and "component" are synonymous.
      The "component" alternative is offered for specifying applications
      that don't use RXER (except for the ASN.X specification itself, of
      course), where referring to parts


   Examples

      SEQUENCE OF INTEGER

      <type>
       <sequenceOf>
        <element name="item" identifier="" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE OF counter INTEGER

      <type>
       <sequenceOf>
        <element name="counter" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

6.12.7.  Translation of an encoding as elements would
      seem incongruous. LIST Types

   The member translation of a NamedType SequenceOfType that is an element item with the
   [local name] "member".

   The item translation of subject to a NamedType LIST
   encoding instruction is an element item with the [local name] "item". "type".
   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <attribute>, <group>, <element>, <component>,
   <member> or <item> <type> element item.

      Aside: A Namedtype for which  An element item with the member or
   [local name] "list" SHALL be appended to the [children] of the <type>
   element item.  The item translation is
      invoked will never of the NamedType in the
   SequenceOfType SHALL be subject added to an ATTRIBUTE, ATTRIBUTE-REF,
      COMPONENT-REF, GROUP or SIMPLE-CONTENT encoding instruction.
      These encoding instructions are also mutually exclusive [RXEREI].

   If a NamedType is subject to a TYPE-AS-VERSION encoding instruction,
   then an attribute item with the [local name] "typeAsVersion" and
   [normalized value] "true" or "1" SHALL be added to [children] of the <element> or
   <component> <list> element
   item.  For

      Aside: A SequenceOfType is necessarily of the normal translation, if
      "SEQUENCE OF NamedType" form for a NamedType
   is not subject to an ATTRIBUTE, ATTRIBUTE-REF, COMPONENT-REF GROUP,
   SIMPLE-CONTENT or TYPE-AS-VERSION LIST encoding instruction, then an
   attribute item with the [local name] "typeAsVersion" and
   [normalized value] "false" or "0" MAY be added to instruction.

   Example

      [RXER:LIST] SEQUENCE OF number INTEGER

      <type>
       <list>
        <item name="number" type="asnx:INTEGER"/>
       </list>
      </type>

6.12.8.  SetOfType Translation

   The translation of a SetOfType follows the <element> or
   <component> element item.

   For same procedure as the normal, member
   translation of a SequenceOfType except that SetOfType replaces
   SequenceOfType, "SET" replaces "SEQUENCE", and item translations, if the [local name]
   "setOf" is used instead of "sequenceOf".



Legg                      Expires 22 June 2007                 [Page 41]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


6.12.9.  Effect of Insertion Encoding Instructions

   If a NamedType Type is not subject to an ATTRIBUTE-REF, COMPONENT-REF, ELEMENT-REF a NO-INSERTIONS, HOLLOW-INSERTIONS,
   SINGULAR-INSERTIONS, UNIFORM-INSERTIONS or
   REF-AS-ELEMENT MULTIFORM-INSERTIONS
   encoding instruction, then an attribute item with the [local name] "name"
   "insertions" SHALL be added to the [attributes] of the
   <attribute>, <group>, <element>, <component>, <member> <choice>,
   <sequence> or <item> <set> element item. item in the [children] of the <type>
   element item resulting from the translation of the Type.  The
   [normalized value] of this attribute item is "none" in the
   value case of a
   NO-INSERTIONS encoding instruction, "hollow" in the local-name component case of a
   HOLLOW-INSERTIONS encoding instruction, "singular" in the effective name [RXEREI] case of
   the NamedType.

      Aside: If there are no NAME, ATTRIBUTE-REF, COMPONENT_REF,
      ELEMENT-REF or REF-AS-ELEMENT a
   SINGULAR-INSERTIONS encoding instructions, then instruction, "uniform" in the
      value case of a
   UNIFORM-INSERTIONS encoding instruction, and "multiform" in the local-name component case
   of the effective name a MULTIFORM-INSERTIONS encoding instruction.

   Example

      [NO-INSERTIONS] CHOICE {
          one  [RXER:GROUP] [RXER:SINGULAR-INSERTIONS] CHOICE {
              two  INTEGER,
              ...
          },
          ...
      }

      <type>
       <choice insertions="none">
        <group name="one">
         <type>
          <choice insertions="singular">
           <element name="two" type="asnx:INTEGER"/>
           <extension/>
          </choice>
         </type>
        </group>
        <extension/>
       </choice>
      </type>

6.13.  Translation of Constrained Types

   If a
      NamedType ConstrainedType is its identifier.

   If the reduction of the local-name component (an NCName) of "Type Constraint" form, then the
   effective name
   translation of the NamedType ConstrainedType is not the same as the identifier of
   the NamedType, then an attribute element item with the
   [local name]



Legg                      Expires 20 April 2007                [Page 42]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   "identifier" SHALL be added to the [attributes] of the <attribute>,
   <group>, <element>, <component>, <member> or <item> "type".  An element item.
   otherwise an attribute item with the [local name] "identifier"
   "annotation" MAY be added to the [attributes] [children] of the aforementioned <type> element
   item.  The
   [normalized value] of this attribute item is the identifier of the
   NamedType.

   If a NamedType is subject to a COMPONENT-REF encoding instruction,
   then an attribute  An element item with the [local name] "ref" "constrained" SHALL be added
   appended to the [attributes] [children] of the <attribute>, <element> or <component> <type> element item.  The [normalized value] of this attribute item is the RXER
   character data
   translation of the effective name of the top-level
   NamedType referenced by the encoding instruction.  If the effective
   name is not distinct with respect Type SHALL be added to the current module and [children] or



Legg                      Expires 22 June 2007                 [Page 42]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   [attributes] of the
   modules referenced by its <import> <constrained> element items (see Section 5.1),
   then an attribute item with item.  The translation of
   the [local name] "context" Constraint SHALL be added to the [attributes] [children] of the <attribute>, <element> or <component> <constrained>
   element item, otherwise item.

   The translation of a ContainedType that is a TypeWithConstraint is
   the translation of the TypeWithConstraint.

   Definition (simple endpoint): A LowerEndpoint or UpperEndpoint is a
   simple endpoint if it is closed and its value is "MIN", "MAX" or a
   SignedNumber in an IntegerValue in a BuiltinValue in the module containing Value of the referenced
   top-level NamedType has
   endpoint.

   Definition (simple range SizeConstraint): A SizeConstraint is a schema identity URI,
   simple range if the Constraint in the SizeConstraint contains only a
   ValueRange (i.e., a ValueRange in a SubtypeElements instance in an
   Elements instance in a lone IntersectionElements instance in a lone
   Intersections instance in a Unions instance in an ElementSetSpec in a
   RootElementSetSpec in an ElementSetSpecs instance without an
   AdditionalElementSetSpec in a SubtypeConstraint in a ConstraintSpec
   in the Constraint) and both endpoints are simple.

   Definition (simple range Constraint): A Constraint is a simple range
   if contains only a SizeConstraint that is a simple range (i.e., a
   simple range SizeConstraint in a SubtypeElements instance in an
   Elements instance in a lone IntersectionElements instance in a lone
   Intersections instance in a Unions instance in an ElementSetSpec in a
   RootElementSetSpec in an ElementSetSpecs instance without an
   AdditionalElementSetSpec in a SubtypeConstraint in a ConstraintSpec
   in the Constraint).

   If the Constraint or SizeConstraint in a TypeWithConstraint is a
   simple range, then the compact translation of the TypeWithConstraint
   MAY be used, otherwise the full translation of the TypeWithConstraint
   is used.

   The compact translation of a TypeWithConstraint is initially the
   translation of its notional parent type.  If the value of the lower
   endpoint is not "MIN" or "0", then an attribute item with the
   [local name] "context" MAY "minSize" SHALL be added to the [attributes] of the <attribute>, <element>
   <sequenceOf>, <setOf> or <component> <list> element item. item resulting from the
   translation of the parent type.  The [normalized value] of this
   attribute item is the schema identity URI value of the module containing the referenced top-level NamedType.

      Aside: lower endpoint.  If an effective name is not distinct, then the module
      containing value of
   the referenced top-level NamedType must have a schema
      identity URI (see Section 5.1).

   If a NamedType lower endpoint is subject to a COMPONENT-REF encoding instruction, "MIN" or "0", then an attribute item with the
   [local name] "embedded" "minSize" and [normalized value] "false" or "0" MAY be added to the
   [attributes] of the <attribute>, <element> <sequenceOf>, <setOf> or <component> <list> element item.  If a NamedType
   the value of the upper endpoint is subject to an ATTRIBUTE-REF or ELEMENT-REF encoding
   instruction, not "MAX", then an attribute item
   with the [local name] "ref" "maxSize" SHALL be added to the [attributes] of
   the <attribute>, <element> <sequenceOf>, <setOf> or
   <component> <list> element item.  The



Legg                      Expires 22 June 2007                 [Page 43]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   [normalized value] of this attribute item is the RXER character data translation value of the QNameValue from upper
   endpoint.

   The full translation of a TypeWithConstraint is an element item with
   the encoding instruction. [local name] "type".  An attribute element item with the [local name]
   "embedded" and [normalized value] "true" or "1" MUST
   "annotation" MAY be added to the
   [attributes] [children] of the <attribute>, <element> or <component> <type> element
   item.

   If a NamedType is subject to a REF-AS-ELEMENT encoding instruction,
   then an attribute  An element item with the [local name] "elementType" "constrained" SHALL be
   added
   appended to the [attributes] [children] of the <element> or <component> <type> element item.  The [normalized value] of this attribute item is the RXER
   character data
   translation of the NameValue from the REF-AS-ELEMENT



Legg                      Expires 20 April 2007                [Page 43]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   encoding instruction.  If the Namespace is present in the
   REF-AS-ELEMENT encoding instruction, then an attribute item with notional parent type of the
   [local name] "namespace" TypeWithConstraint
   SHALL be added to the [children] or [attributes] of the
   <element> or <component> <constrained>
   element item.  The [normalized value] translation of
   this attribute item is the string value of Constraint or SizeConstraint in
   the AnyURIValue in TypeWithConstraint SHALL be added to the
   Namespace.

   If [children] of the ContextParameter
   <constrained> element item.

   Examples

      SEQUENCE (SIZE(1..MAX)) OF number INTEGER

      <type>
       <sequenceOf minSize="1">
        <element name="number" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE SIZE(0..10) OF number INTEGER

      <type>
       <sequenceOf maxSize="10">
        <element name="number" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE SIZE(1..limit) OF number INTEGER

      <type>
       <constrained>
        <type>
         <sequenceOf>
          <element name="number" type="asnx:INTEGER"/>
         </sequenceOf>
        </type>
        <size>
         <range>
          <minInclusive literalValue="1"/>
          <maxInclusive value="tns:limit"/>
         </range>
        </size>
       </constrained>



Legg                      Expires 22 June 2007                 [Page 44]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


      </type>

6.13.1.  Constraint Translation

   The translation of a Constraint is present in the RefParameters translation of the
   ConstraintSpec in the
   ATTRIBUTE-REF, ELEMENT-REF or REF-AS-ELEMENT encoding instruction,
   then an attribute item with Constraint followed by the [local name] "context" SHALL be added
   to translation of the [attributes]
   ExceptionSpec (possibly empty) in the Constraint.

   The translation of a ConstraintSpec is the <attribute>, <element> translation of the
   SubtypeConstraint or <component>
   element item. GeneralConstraint in the ConstraintSpec.

   The [normalized value] translation of this attribute item a SubtypeConstraint is the
   string value translation of the AnyURIValue
   ElementSetSpecs in the ContextParameter.

   If SubtypeConstraint.

   The translation of a NamedType GeneralConstraint is subject to an ATTRIBUTE encoding instruction and the translation of the
   UserDefinedConstraint, TableConstraint or ContentsConstraint in the
   GeneralConstraint.

6.13.2.  UserDefinedConstraint Translation

   The translation of a
   VERSION-INDICATOR encoding instruction, then UserDefinedConstraint is an attribute element item with
   the [local name] "versionIndicator" and [normalized value] "true" or
   "1" SHALL be added to the <attribute> "constrainedBy".  An element item.  If a NamedType
   is subject to an ATTRIBUTE encoding instruction and not subject to a
   VERSION-INDICATOR encoding instruction, then an attribute item with the
   [local name] "versionIndicator" and [normalized value] "false" or
   "0" "annotation" MAY be added to the <attribute> [children] of the
   <constrainedBy> element item.

   If  The translation of each
   UserDefinedConstraintParameter in the UserDefinedConstraint SHALL be
   appended to the [children] of the <constrainedBy> element item.

   The translation of a NamedType UserDefinedConstraintParameter of the
   "Governor : Value" form is not subject to an ATTRIBUTE-REF, COMPONENT-REF,
   ELEMENT-REF or REF-AS-ELEMENT encoding instruction, then element item with the [local name]
   "valueParameter".  The translation of the Type in the NamedType Governor SHALL
   be added to the [children] or [attributes] of the <attribute>, <group>, <element>,
   <component>, <member> or <item> <valueParameter>
   element item.  If  The translation of the enclosing
   combining type is a SEQUENCE, SET or CHOICE type and Value SHALL be added to the Type in
   [children] or [attributes] of the
   NamedType is <valueParameter> element item.

   The translation of a DummyReference and the TagDefault for the module
   containing UserDefinedConstraintParameter of the NamedType
   "Governor : ValueSet" form is "AUTOMATIC TAGS", then an attribute form element item with the [local name]
   "valueSetParameter".  The translation of the Type in the NamedType Governor
   SHALL NOT be used, and an
   attribute item with added to the [local name] "explicit" and
   [normalized value] "true" [children] or "1" [attributes] of the
   <valueSetParameter> element item.  The translation of the ValueSet
   SHALL be added to the [attributes] [children] of the <type> <valueSetParameter> element
   item.

   The translation of a UserDefinedConstraintParameter of the
   "Governor : Object" form is an element item resulting from with the [local name]
   "objectParameter".  The translation of the Type DefinedObjectClass in the NamedType.  Where the automatic tagging transformation applies
   [X.680], this attribute item indicates that explicit tagging applies
   Governor SHALL be added to the Type in the NamedType instead of the usual implicit tagging.

   If a NamedType is subject to an ATTRIBUTE-REF, COMPONENT-REF,
   ELEMENT-REF [children] or REF-AS-ELEMENT encoding instruction, then [attributes] of the
   <objectParameter> element item.  The translation of each EncodingPrefix (Section 6.7) and Tag
   (Section 6.7.2) textually within the NamedType Object SHALL
   be added in
   order to the [children] or [attributes] of the <attribute>, <element> or <component>
   element item.

   Example <objectParameter>



Legg                      Expires 20 April 22 June 2007                 [Page 44] 45]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      CHOICE {
          one    INTEGER,
          two    [RXER:ATTRIBUTE] BOOLEAN,
          three  [RXER:ATTRIBUTE-REF
                     { namespace-name "http://www.example.com/schema",
                       local-name "foo" }]
                 UTF8String,
          bar    [RXER:ELEMENT-REF
                     { namespace-name "http://www.example.com/schema",
                       local-name "bar" }]
                 Markup,
          five   [0] [RXER:REF-AS-ELEMENT "product"
                     CONTEXT "http://www.example.com/inventory"]
                 Markup,
          six    [RXER:GROUP] MySequence
      }

      <type>
       <choice xmlns:ex="http://www.example.com/schema">
        <element name="one" type="asnx:INTEGER"/>
        <attribute name="two" type="asnx:BOOLEAN"/>
        <attribute ref="ex:foo" identifier="three" embedded="true"/>
        <element ref="ex:bar" embedded="true"/>
        <element elementType="product"
                 context="http://www.example.com/inventory"
                 identifier="five">
         <TAG number="0"/>
        </element>
        <group name="six" type="tns:MySequence"/>
       </choice>
      </type>

6.12.2.  SequenceType Translation


   element item.

   The translation of a SequenceType UserDefinedConstraintParameter of the
   "Governor : ObjectSet" form is an element item with the [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children]
   "objectSetParameter".  The translation of the <type> element
   item.  An element item with DefinedObjectClass in
   the [local name] "sequence" Governor SHALL be
   appended added to the [children] or [attributes] of the <type>
   <objectSetParameter> element item.  The translation of each ComponentType in the ComponentTypeList of the
   initial RootComponentTypeList, if present, ObjectSet
   SHALL be appended added to the [children] or [attributes] of the <sequence>
   <objectSetParameter> element item.

   If the ExtensionAndException

   The translation of a UserDefinedConstraintParameter that is a Type is present, then
   an element item with the [local name] "extension" SHALL be appended to the [children] of
   the <sequence> element item, and the "typeParameter".  The
   translation of the ExceptionSpec
   (possibly empty) Type SHALL be added to the [children] of the <extension>
   element item.



Legg                      Expires 20 April 2007                [Page 45]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   The translation of each ExtensionAdditionGroup or ComponentType
   nested in the ExtensionAdditions (if any) SHALL be appended to the
   [children] of the <extension> element item.

   If the ExtensionEndMarker is present, then the translation of each
   ComponentType in the final RootComponentTypeList SHALL be appended to
   the [children]
   [attributes] of the <sequence> <typeParameter> element item.

   The translation of an ExtensionAdditionGroup a UserDefinedConstraintParameter that is a
   DefinedObjectClass is an element item with the [local name] "extensionGroup".  If the VersionNumber is present,
   then an attribute item with
   "classParameter".  The translation of the [local name] "version" DefinedObjectClass SHALL be
   added to the [children] or [attributes] of the <extensionGroup> <classParameter>
   element item.  The
   [normalized value] of this attribute item is the number of

   Example

      OCTET STRING
          (CONSTRAINED BY {
              -- contains the
   VersionNumber.  The translation hash of each ComponentType in the
   ExtensionAdditionGroup SHALL be appended to value -- MyType:myValue })

      <type>
       <constrained type="asnx:OCTET-STRING">
        <constrainedBy>
         <annotation> contains the [children] hash of the
   <extensionGroup> element item. value </annotation>
         <valueParameter type="tns:MyType" value="tns:myValue"/>
        </constrainedBy>
       </constrained>
      </type>

6.13.3.  TableConstraint Translation

   The translation of a ComponentType of the "NamedType" form TableConstraint that is the
   normal translation of the NamedType.

   The translation of a ComponentType of the "NamedType OPTIONAL" form SimpleTableConstraint
   is an element item with the [local name] "optional". "table".  The normal translation of
   the NamedType ObjectSet in the SimpleTableConstraint SHALL be added to the
   [children] or [attributes] of the
   <optional> <table> element item.

   The translation of a ComponentType of the "NamedType DEFAULT Value"
   form TableConstraint that is a
   ComponentRelationConstraint is an element item with the [local name] "optional".
   "table".  The normal translation of the NamedType SHALL be added to the [children] of the
   <optional> element item.  An element item with DefinedObjectSet in the [local name]
   "default"
   ComponentRelationConstraint SHALL be appended added to the [children] or
   [attributes] of the <optional> <table> element item.  The translation of each



Legg                      Expires 22 June 2007                 [Page 46]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   AtNotation in the Value ComponentRelationConstraint SHALL be added appended to
   the [children] or [attributes] of the <default> <table> element item.

   The translation of a ComponentType of the "COMPONENTS OF Type" form an AtNotation is an element item with the
   [local name] "componentsOf". "restrictBy".  The
   translation [children] property of the Type SHALL be added
   <restrictBy> element item is set to the [children] or
   [attributes] sequence of character items
   for the <componentsOf> element item.

   Example

      SEQUENCE { character string formed by the concatenation of zero, one    INTEGER,
          two    [RXER:ATTRIBUTE] BOOLEAN OPTIONAL,
          ...,
          [[ 2:
              four   NULL
          ]],
          COMPONENTS OF MySequence,



Legg                      Expires 20 April 2007                [Page 46]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


          ...,
          three   PrintableString DEFAULT "third"
      }

      <type>
       <sequence>
        <element name="one" type="asnx:INTEGER"/>
        <optional>
         <attribute name="two" type="asnx:BOOLEAN"/>
        </optional>
        <extension>
         <extensionGroup version="2">
          <element name="four" type="asnx:NULL"/>
         </extensionGroup>
         <componentsOf type="tns:MySequence"/>
        </extension>
        <optional>
         <element name="three" type="asnx:PrintableString"/>
         <default literalValue="third"/>
        </optional>
       </sequence>
      </type>

6.12.3.  SetType Translation

   The translation of a SetType follows or
   more "../" strings, one for each Level in the same procedure as a
   SequenceType except that SetType replaces SequenceType, "SET"
   replaces "SEQUENCE", and AtNotation (including
   the [local name] "set" is used instead empty one), followed by a solidus ('/', U+002F) separated list of
   "sequence".

6.12.4.  ChoiceType Translation

   The translation
   qualified names for the expanded names of the NamedType instances
   [RXEREI] identified by the identifiers in the ComponentIdList in the
   AtNotation.  If a ChoiceType that NamedType is not subject to an ATTRIBUTE or
   ATTRIBUTE-REF encoding instruction, or subject to a UNION COMPONENT-REF
   encoding instruction that references a top-level NamedType that is
   subject to an element item with ATTRIBUTE encoding instruction, then the [local name] "type".
   An element item qualified name
   for the expanded name is prefixed with the [local name] "annotation" commercial at character
   ('@', U+0040).  Leading and/or trailing white space character items
   MAY be added to the [children] of the <type> <restrictBy> element item.
   White space character items MAY be added immediately before and/or
   after any character item for the solidus character ('/', U+002F).

   Examples

      ERROR.&Type({Errors}{@severity,@...errorId})

      <type>
       <constrained>
        <type>
         <fromClass class="tns:ERROR" fieldName="Type"/>
        </type>
        <table objectset="tns:Errors">
         <restrictBy>severity</restrictBy>
         <restrictBy>../../../errorId</restrictBy>
        </table>
       </constrained>
      </type>

      SEQUENCE {
          id-att  [RXER:NAME AS "ID"] [RXER:ATTRIBUTE]
                      TYPE-IDENTIFIER.&id({AllTypes}),
          value   TYPE-IDENTIFIER.&Type({AllTypes}{@id-att})
      }

      <type>
       <sequence>
        <attribute name="ID" identifier="id-att">
         <type>
          <constrained>



Legg                      Expires 22 June 2007                 [Page 47]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


           <type>
            <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="id"/>
           </type>
           <table objectset="tns:AllTypes"/>
          </constrained>
         </type>
        </attribute>
        <element name="value">
         <type>
          <constrained>
           <type>
            <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="Type"/>
           </type>
           <table objectset="tns:AllTypes">
            <restrictBy>@ID</restrictBy>
           </table>
          </constrained>
         </type>
        </element>
       </sequence>
      </type>

   The <restrictBy> element item is required to be self-contained
   [RXER].

      Aside: An element item is self-contained if all namespace prefixes
      used by the element item and its contents are declared within the
      element item.

6.13.4.  ContentsConstraint Translation

   The translation of a ContentsConstraint is an element item with the
   [local name] "choice" "contents".

   If the ContentsConstraint is of the "CONTAINING Type" form, then an
   element item with the [local name] "containing" SHALL be appended added to the
   [children] of the
   <type> <contents> element item.  The normal translation of each NamedType in the
   AlternativeTypeList in the RootAlternativeTypeList
   Type SHALL be appended added to the [children] or [attributes] of the <choice>
   <containing> element item.

   If the ExtensionAndException ContentsConstraint is present, of the "ENCODED BY Value" form, then an
   element item with the [local name] "extension" is appended "encodedBy" SHALL be added to the
   [children] of the
   <choice> <contents> element item, and the item.  The translation of the ExceptionSpec
   (possibly empty) is
   Value SHALL be added to the [children] or [attributes] of the <extension>
   <encodedBy> element item.

   The translation

   If the ContentsConstraint is of each ExtensionAdditionAlternativesGroup or the
   "CONTAINING Type ENCODED BY Value" form, then an element item with



Legg                      Expires 20 April 22 June 2007                 [Page 47] 48]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   NamedType in


   the ExtensionAdditionAlternatives (if any) [local name] "containing" and an element item with the
   [local name] "encodedBy" SHALL be
   appended added to the [children] of the <extension>
   <contents> element item.  The
   normal translation of the NamedType is used. Type SHALL be added
   to the [children] or [attributes] of the <containing> element item.
   The translation of the Value SHALL be added to the [children] or
   [attributes] of the <encodedBy> element item.

   Example

      OCTET STRING
          (CONTAINING MyType
           ENCODED BY { joint-iso-itu-t asn1(1) basic-encoding(1) })

      <type>
       <constrained type="asnx:OCTET-STRING">
        <contents>
         <containing type="tns:MyType"/>
         <encodedBy literalValue="2.1.1"/>
        </contents>
       </constrained>
      </type>

6.13.5.  ExceptionSpec Translation

   The translation of an ExtensionAdditionAlternativesGroup empty ExceptionSpec is empty.

   The translation of a non-empty ExceptionSpec is an element item with
   the [local name] "extensionGroup". "exception".

   If the
   VersionNumber ExceptionIdentification in a non-empty ExceptionSpec is present, a
   SignedNumber, then an attribute item with the
   [local name] "version" translation of a notional INTEGER Type SHALL
   be added to the [children] or [attributes] of the
   <extensionGroup> <exception> element item.  The [normalized value] of this
   attribute
   item is the number of and the VersionNumber.  The normal translation of each NamedType in a notional Value of the
   ExtensionAdditionAlternativesGroup INTEGER type with
   the SignedNumber as its IntegerValue SHALL be appended added to the [children]
   or [attributes] of the <extensionGroup> <exception> element item.

   Example

      CHOICE {
          one  INTEGER,
          two  [RXER:NAME AS "Two"] BOOLEAN,
          ...,
          [[ 2:
              three  NULL
          ]],
          four  PrintableString,
          ...
      }

      <type>
       <choice>
        <element name="one" type="asnx:INTEGER"/>
        <element name="Two" type="asnx:BOOLEAN"/>
        <extension>
         <extensionGroup version="2">
          <element name="three" type="asnx:NULL"/>
         </extensionGroup>
         <element name="four" type="asnx:PrintableString"/>
        </extension>
       </choice>
      </type>

6.12.5.  Translation of UNION Types

   The translation of a ChoiceType that is subject to a UNION encoding
   instruction follows

   If the same procedure as ExceptionIdentification in a ChoiceType that non-empty ExceptionSpec is not
   subject to a UNION encoding instruction except that the [local name]
   "union" is used instead of "choice", and
   DefinedValue, then the member translation of
   each NamedType is used instead of the normal translation.




Legg                      Expires 20 April 2007                [Page 48]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   In addition, if the UNION encoding instruction has a PrecedenceList,
   then an attribute item with the [local name] "precedence" notional INTEGER Type SHALL
   be added to the [children] or [attributes] of the <union> <exception> element item.  The
   [normalized value] of this attribute
   item is the white space
   separated list of the RXER character data translations of the
   effective names [RXEREI] of the NamedType instances corresponding to
   the identifiers in and the PrecedenceList.

   Example

      [RXER:UNION PRECEDENCE utf8 visible] CHOICE {
          printable  PrintableString,
          teletex    TeletexString,
          visible    [RXER:NAME AS "ascii"] VisibleString,
          ...,
          utf8       UTF8String
      }

      <type>
       <union precedence="utf8 ascii">
        <member name="printable" type="asnx:PrintableString"/>
        <member name="teletex" type="asnx:TeletexString"/>
        <member name="ascii" identifier="visible"
                type="asnx:VisibleString"/>
        <extension>
         <member name="utf8" type="asnx:UTF8String"/>
        </extension>
       </union>
      </type>

6.12.6.  SequenceOfType Translation

   The translation of a SequenceOfType that is not subject to a LIST
   encoding instruction is an element item with the [local name] "type".
   An element item with the [local name] "annotation" MAY be added to
   the [children] of the <type> element item.  An element item with the
   [local name] "sequenceOf" DefinedValue SHALL be appended added to the
   [children] or [attributes] of the
   <type> <exception> element item.

   If the SequenceOfType ExceptionIdentification in a non-empty ExceptionSpec is of the "SEQUENCE OF NamedType"
   "Type : Value" form, then the normal translation of the NamedType Type SHALL be added
   to the [children] or [attributes] of the <sequenceOf> <exception> element item.

   If item and
   the SequenceOfType is translation of the "SEQUENCE OF Type" form, then an
   element item with the [local name] "element" or "component"
   (translator's choice) Value SHALL be added to the [children] or
   [attributes] of the <type> <exception> element item.  An attribute item with the [local name] "name" and
   [normalized value] "item" SHALL be added to the [attributes] of the




Legg                      Expires 20 April 22 June 2007                 [Page 49]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   <element> or <component> element item.  An attribute item with the
   [local name] "identifier" and empty [normalized value] SHALL be added
   to the [attributes] of the <element> or <component> element item.
   The translation of the Type SHALL be added to the [children] or
   [attributes] of the <element> or <component> element item.


   Examples

      SEQUENCE OF INTEGER

      <type>
       <sequenceOf>
        <element name="item" identifier="" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE OF counter INTEGER

      <type>
       <sequenceOf>
        <element name="counter" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

6.12.7.

      !10

      <exception type="asnx:INTEGER" literalValue="10"/>

      !myValue

      <exception type="asnx:INTEGER" value="tns:myValue"/>

      !PrintableString:"failure"

      <exception type="asnx:PrintableString" literalValue="failure"/>

7.  Translation of LIST Types

   The Values

   A Value in an ASN.1 specification is a mix of literal values (e.g.,
   numbers and character strings) and notations for referencing defined
   values.  Likewise, the ASN.X translation of a SequenceOfType that Value is subject to a LIST
   encoding instruction is an element item with the [local name] "type".
   An element item with the [local name] "annotation" MAY be added to
   the [children] mix of
   markup for literal values and markup for referencing notations
   (notational values).  A Value is categorized by the <type> element item.  An element item with the
   [local name] "list" SHALL be appended to the [children] of the <type>
   element item.  The item translation of the NamedType SHALL be added
   to the [children] of the <list> element item.

      Aside: SequenceOfType following
   definitions.

   Definition (literal value): A Value is necessarily of the
      "SEQUENCE OF NamedType" form for a LIST encoding instruction.

   Example

      [RXER:LIST] SEQUENCE OF number INTEGER

      <type>
       <list>
        <item name="number" type="asnx:INTEGER"/>
       </list>
      </type>

6.12.8.  SetOfType Translation



Legg                      Expires 20 April 2007                [Page 50]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   The translation of literal value if and only if
   it is not a SetOfType follows the same procedure as notational value.

   Definition (notational value): A Value is a
   SequenceOfType except that SetOfType replaces SequenceOfType, "SET"
   replaces "SEQUENCE", notational value if and
   only if:

   (1) the [local name] "setOf" Value is used instead of
   "sequenceOf".

6.12.9.  Insertion Encoding Instructions

   If a Type BuiltinValue, and

       (a) the BuiltinValue is subject to a NO-INSERTIONS, HOLLOW-INSERTIONS,
   SINGULAR-INSERTIONS, UNIFORM-INSERTIONS or MULTIFORM-INSERTIONS
   encoding instruction, then an attribute item with TaggedValue and the [local name]
   "insertions" SHALL be added to Value in the [attributes] of
           TaggedValue is a notational value, or

       (b) the <choice>,
   <sequence> BuiltinValue is a SequenceValue or <set> element item in SetValue with a
           ComponentValueList that contains a NamedValue where the [children] of Value
           in the <type>
   element item resulting from NamedValue is a notational value and the translation
           of the Type.  The
   [normalized value] of this attribute item is "none" in corresponding NamedType (from the case governing type of a
   NO-INSERTIONS encoding instruction, "hollow" in
           the case of a
   HOLLOW-INSERTIONS encoding instruction, "singular" in outer Value) is not an <element> or <component> element
           item, or

       (c) the case of BuiltinValue is a
   SINGULAR-INSERTIONS encoding instruction, "uniform" in ChoiceValue where the case Value of the
           ChoiceValue is a
   UNIFORM-INSERTIONS encoding instruction, notational value and "multiform" in the case
   of a MULTIFORM-INSERTIONS encoding instruction.

   Example

      [NO-INSERTIONS] CHOICE {
          one  [RXER:GROUP] [RXER:SINGULAR-INSERTIONS] CHOICE {
              two  INTEGER,
              ...
          },
          ...
      }

      <type>
       <choice insertions="none">
        <group name="one">
         <type>
          <choice insertions="singular">
           <element name="two" type="asnx:INTEGER"/>
           <extension/>
          </choice>
         </type>
        </group>
        <extension/>
       </choice>
      </type>

6.13.  Translation of Constrained Types

   If a ConstrainedType is translation of the "Type Constraint" form, then
           NamedType corresponding to the
   translation of identifier in the ConstrainedType ChoiceValue
           is not an <element> or <component> element item item, or

       (d) the BuiltinValue is a SequenceOfValue or SetOfValue with a
           NamedValueList that contains a NamedValue where the Value of



Legg                      Expires 20 April 22 June 2007                 [Page 51] 50]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the [children] of the <type> element
   item.  An element item with the [local name] "constrained" SHALL be
   appended to


           the [children] of NamedValue is a notational value and the <type> element item.  The translation of
           the Type SHALL be added to corresponding NamedType (from the [children] or
   [attributes] governing type of the <constrained>
           outer Value) is not an <element> or <component> element item.  The translation of
   the Constraint SHALL be added to the [children] of item,
           or

   (2) the <constrained>
   element item.

   The translation of a ContainedType that Value is a TypeWithConstraint is
   the translation of ReferencedValue, and

       (a) the TypeWithConstraint.

   Definition (simple endpoint): A LowerEndpoint or UpperEndpoint ReferencedValue is a
   simple endpoint if it ValueFromObject, or

       (b) the ReferencedValue is closed a DefinedValue, and its value

           (i)   the DefinedValue is "MIN", "MAX" or a
   SignedNumber in valuereference (not a
                 DummyReference) or an IntegerValue in ExternalValueReference, or

           (ii)  the DefinedValue is a BuiltinValue in DummyReference or
                 ParameterizedValue and the Value of substitute definition for
                 the
   endpoint.

   Definition (simple range SizeContraint): A SizeConstraint DummyReference or ParameterizedValue (see
                 Section 13) is a simple
   range if the Constraint in notational value, or

           (iii) the SizeConstraint contains only a
   ValueRange (i.e., a ValueRange in a SubtypeElements in an Elements in
   a single IntersectionElements in DefinedValue is a single Intersections in DummyReference or
                 ParameterizedValue where the translation of the
                 DummyReference or ParameterizedValue will use a Unions
   in fully
                 expanded reference (see Section 13), or

   (3) the Value is an ElementSetSpec in a lone RootElementSetSpec in ObjectClassFieldValue, and

       (a) the ObjectClassFieldValue is an
   ElementSetSpecs in a SubtypeConstraint in a lone ConstraintSpec in OpenTypeFieldVal, or

       (b) the Constraint) and both endpoints are simple.

   Definition (simple range Contraint): A Constraint ObjectClassFieldValue is a simple range
   if contains only FixedTypeFieldVal, and

           (i)  the FixedTypeFieldVal is a SizeConstraint BuiltinValue that satisfies
                case (1), or

           (ii) the FixedTypeFieldVal is a simple range (i.e., a
   simple range SizeConstraint in a SubtypeElements in an Elements in a
   single IntersectionElements in a single Intersections in a Unions in
   an ElementSetSpec in a lone RootElementSetSpec in an ElementSetSpecs
   in ReferencedValue that
                satisfies case (2).

   A literal value that is a SubtypeConstraint in BuiltinValue that is a lone ConstraintSpec in the Constraint).

   If the Constraint SequenceValue,
   SetValue, ChoiceValue, SequenceOfValue or SizeConstraint in SetOfValue MAY be
   translated as a TypeWithConstraint notational value.

   Definition (directly nested): A notational value is directly nested
   (within a
   simple range, then literal value) if the compact innermost enclosing Value is a
   literal value.

7.1.  Translation of Literal Values

   The translation of a literal value is either the TypeWithConstraint
   MAY be used, otherwise the full attribute form
   translation of a literal value, or the TypeWithConstraint
   is used.

   The compact element form translation of a TypeWithConstraint is the



Legg                      Expires 22 June 2007                 [Page 51]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   literal value.

   The attribute form translation of
   the parent type.  If the a literal value of the lower endpoint is not "MIN" or
   "0", then an attribute
   item with the [local name] "minSize" SHALL be
   added to the [attributes] of the <sequenceOf>, <setOf> or <list>
   element item from the translation of the parent type. "literalValue".  The [normalized value] of
   this attribute item is the value of the lower
   endpoint.  If the value RXER character data translation [RXER] of
   the lower endpoint is "MIN" or "0", then
   an literal value.

   The attribute item with the [local name] "minSize" and
   [normalized value] "0" MAY form translation of a literal value SHALL NOT be added to used
   if:

   (1) the [attributes] RXER Infoset translation of the
   <sequenceOf>, <setOf> or <list> element item.  If the literal value of the
   upper endpoint is not "MAX", then an a
       character data translation [RXER] or is a character data
       translation that contains qualified names [XMLNS10][XMLNS11], or

   (2) attribute item with the



Legg                      Expires 20 April 2007                [Page 52]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   [local name] "maxSize" SHALL be added to the [attributes] form translations of Value have been explicitly
       disallowed in the
   <sequenceOf>, <setOf> or <list> element item.  The [normalized value]
   of this attribute item is context where the literal value of appears, or

   (3) the upper endpoint. literal value has a nested notational value.

   The full element form translation of a TypeWithConstraint literal value is an element item
   with the [local name] "type".  An element item with the [local name]
   "annotation" MAY be added to the "literalValue".  The [children] and
   [attributes] of the <type> element
   item.  An <literalValue> element item with the [local name] "constrained" SHALL be
   appended are set to the [children] of the <type> element item.  The RXER
   Infoset translation of the parent type SHALL be added literal value, except that a value of the
   EXTERNAL type (or a subtype thereof) is translated according to the
   associated type defined in Clause 34.5 of X.680 [X.680].  In
   addition, where the [children] or and [attributes] of the <constrained> an element item.  The item in
   the translation correspond to a directly nested notational value, the
   translation specified in Section 7.2 MUST be used for the [children]
   and [attributes] of that element item, and an attribute item with the Constraint
   [local name] "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and [normalized value] "false" or SizeConstraint SHALL "0"
   (i.e., asnx:literal="false") MUST be added to the [children] [attributes] of
   that element item.

   Each outermost <literalValue> element item is required to be
   self-contained [RXER].

      Aside: An element item is self-contained if all namespace prefixes
      used by the element item and its contents are declared within the <constrained>
      element item.

   Examples

      SEQUENCE (SIZE(1..MAX)) OF number INTEGER

      <type>
       <sequenceOf minSize="1">
        <element name="number" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE SIZE(0..10) OF number INTEGER

      <type>
       <sequenceOf maxSize="10">
        <element name="number" type="asnx:INTEGER"/>
       </sequenceOf>
      </type>

      SEQUENCE SIZE(1..limit) OF number INTEGER

      <type>
       <constrained>
        <type>
         <sequenceOf>
          <element name="number" type="asnx:INTEGER"/>
         </sequenceOf>
        </type>
        <size>
         <range>
          <minInclusive literalValue="1"/>
          <maxInclusive value="tns:limit"/>
         </range>
        </size>
       </constrained>

      Aside: A <literalValue> element item nested within another
      <literalValue> element item is not required to be self-contained.

   An attribute item with the [local name] "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and [normalized value] "true" or "1"
   (i.e., asnx:literal="true") MAY be added to the [attributes] of the
   <literalValue> element item and/or any nested element item with



Legg                      Expires 20 April 22 June 2007                 [Page 53] 52]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


      </type>

6.13.1.  Constraint Translation


   content and attributes that correspond to a literal value.

      Aside: The translation of asnx:literal attribute operates as a Constraint switch that
      indicates whether the content and other attributes of the element
      containing the attribute are interpreted as ASN.X notation (a
      notational value) or as an RXER encoding (a literal value).

   Example

      zero INTEGER ::= 0

      <namedValue name="zero" type="asnx:INTEGER" literalValue="0"/>

          OR

      <namedValue name="zero" type="asnx:INTEGER">
       <literalValue>0</literalValue>
      </namedValue>

   From the perspective of an ASN.X module as the RXER encoding of an
   ASN.1 value (an abstract value of the ModuleDefinition type in
   Appendix A), the type of the <literalValue> element is the translation
   unconstrained Markup type [RXER], not the governing type of the
   ConstraintSpec followed by Value
   according to the translation ASN.1 specification.  This means that the Infoset
   representation of the ExceptionSpec
   (possibly empty).

   The translation <literalValue> element must be preserved in
   re-encodings of a ConstraintSpec the ASN.X module.

   Similarly, the type of the literalValue attribute is a UTF8String,
   not the translation governing type of the
   contained SubtypeConstraint or GeneralConstraint. Value according to the ASN.1
   specification.  This means that the exact characters of the
   [normalized value] of the attribute must be preserved in re-encodings
   of the ASN.X module.

7.2.  Translation of Notational Values

   The translation of a SubtypeConstraint notational value is the translation of the
   contained ElementSetSpecs.
   BuiltinValue, ReferencedValue or ObjectClassFieldValue in the
   notational value.

   The translation of a GeneralConstraint ReferencedValue is the translation of the
   contained UserDefinedConstraint, TableConstraint
   DefinedValue or
   ContentsConstraint.

6.13.2.  UserDefinedConstraint Translation ValueFromObject in the ReferencedValue.

   The translation for each of a UserDefinedConstraint these cases is described as creating an
   element item with the [local name] "constrainedBy".  An element item with "value", which is appropriate for
   a notational value that stands on its own.  However, a notational
   value may also be directly nested within a literal value, in which
   case the [local name] "annotation" MAY will be added determined according to RXER and the [children] of the
   <constrainedBy> element item.  The translation
   governing ASN.1 type of each
   UserDefinedConstraintParameter SHALL be appended to the [children] of enclosing literal value.



Legg                      Expires 22 June 2007                 [Page 53]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


      Aside: In the latter case, the <constrainedBy> element item.

   The translation of item will also have a UserDefinedConstraintParameter of
      literal attribute item with the
   "Governor : Value" form [normalized value] "false" or "0".

   A notational value that is not directly nested within a literal value
   MAY instead have the [local name] "literalValue" provided an element
   attribute item with the [local name]
   "valueParameter".  The translation of the Type in the Governor "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and
   the translation of the Value SHALL be [normalized value] "false" or "0"
   is added to the [children] and/or [attributes] of the <valueParameter> <literalValue> element item.

   The

   Examples

      nothing INTEGER ::= zero

      <namedValue name="nothing" type="asnx:INTEGER" value="tns:zero"/>

          OR

      <namedValue name="nothing" type="asnx:INTEGER">
       <value ref="tns:zero"/><!-- A notational value. -->
      </namedValue>

          OR

      <namedValue name="nothing" type="asnx:INTEGER">
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule"
                     asnx:literal="false"
                     ref="tns:zero"/><!-- A notational value. -->
      </namedValue>

      integerList SEQUENCE OF number INTEGER ::= { zero, 3, 7 }

      <namedValue name="integerList">
       <type>
        <sequenceOf>
         <element name="number" type="asnx:INTEGER"/>
        </sequenceOf>
       </type>
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule">
        <number asnx:literal="false"
                ref="tns:zero"/><!-- A notational value. -->
        <number>3</number><!-- A literal value. -->
        <number>7</number><!-- A literal value. -->
       </literalValue>
      </namedValue>

7.2.1.  DefinedValue Translation



Legg                      Expires 22 June 2007                 [Page 54]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   If a DefinedValue is a valuereference (not a DummyReference) or an
   ExternalValueReference, then the translation of a UserDefinedConstraintParameter the DefinedValue is
   either the attribute form translation of a value reference, or the
   "Governor : ValueSet"
   element form translation of a value reference.

   The attribute form translation of a value reference is an element attribute
   item with the [local name]
   "valueSetParameter". "value".  The translation [normalized value] of this
   attribute item is a qualified name for the Type in the Governor
   SHALL be added to the [children] or [attributes] expanded name of the
   <valueSetParameter> element item.
   referenced value definition (see Section 5.1).  The attribute form
   translation of the ValueSet SHALL NOT be added used if this expanded name is not distinct
   with respect to the [children] of current module and the <valueSetParameter> modules referenced by its
   <import> element
   item. items (see Section 5.1).

   The element form translation of a UserDefinedConstraintParameter of the
   "Governor : Object" form value reference is an element item
   with the [local name]
   "objectParameter".  The translation of the DefinedObjectClass in the
   Governor and the translation of "value".  An element item with the Object SHALL [local name]
   "annotation" MAY be added to the [children] and/or [attributes] of the <objectParameter> <value> element
   item.

   The translation of a UserDefinedConstraintParameter of the



Legg                      Expires 20 April 2007                [Page 54]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   "Governor : ObjectSet" form is an element  An attribute item with the [local name]
   "objectSetParameter".  The translation of the DefinedObjectClass in
   the Governor and the translation of the ObjectSet "ref" SHALL be added
   to the [children] and/or [attributes] of the <objectSetParameter> <value> element item.  The translation
   [normalized value] of a UserDefinedConstraintParameter that this attribute item is a Type qualified name for the
   expanded name of the referenced value definition.  If this expanded
   name is
   an not distinct with respect to the current module and the
   modules referenced by its <import> element items, then an attribute
   item with the [local name] "typeParameter".  The
   translation of the Type "context" SHALL be added to the [children] or
   [attributes] of the <typeParameter> <value> element item.

   The translation of a UserDefinedConstraintParameter that is item, otherwise if the module
   containing the referenced value definition has a
   DefinedObjectClass is schema identity URI,
   then an element attribute item with the [local name]
   "classParameter".  The translation of the DefinedObjectClass SHALL "context" MAY be added
   to the [children] or [attributes] of the <classParameter> <value> element item.

   Example

      OCTET STRING
          (CONSTRAINED BY {
              -- contains  The
   [normalized value] of this attribute item is the hash schema identity URI
   of the module containing the value -- MyType:myValue })

      <type>
       <constrained type="asnx:OCTET-STRING">
        <constrainedBy>
         <annotation> contains definition referenced by the hash
   DefinedValue.

      Aside: If a reference name is not distinct, then the module
      containing the referenced definition must have a schema identity
      URI (see Section 5.1).

   Usually the translator is free to choose either an attribute form or
   element form translation for a DefinedValue, however in some contexts
   attribute forms of Value are explicitly disallowed.  In particular,
   the attribute form translation SHALL NOT be used for a DefinedValue
   in a ReferencedValue in a Value that is directly nested in a literal
   value.

   If a DefinedValue is a DummyReference or ParameterizedValue, then the
   translation of the value </annotation>
         <valueParameter type="tns:MyType" value="tns:myValue"/>
        </constrainedBy>
       </constrained>
      </type>

6.13.3.  TableConstraint DefinedValue is the translation of that
   DummyReference or ParameterizedValue (see Section 13).

7.2.2.  BuiltinValue Translation




Legg                      Expires 22 June 2007                 [Page 55]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   The translation of a TableConstraint BuiltinValue is the translation of the
   ChoiceValue, SequenceValue, SetValue, SequenceOfValue, SetOfValue or
   TaggedValue in the BuiltinValue.

      Aside: There are other possibilities for a BuiltinValue, but these
      will all be literal values.  This section applies to a
      BuiltinValue that is a SimpleTableConstraint notational value.

   The translation of a TaggedValue is the translation of the Value in
   the TaggedValue (which is necessarily a notational value).

   The translation of a ChoiceValue is an element item with the
   [local name] "table".  The translation of
   the ObjectSet in "value".  An element item with the SimpleTableConstraint SHALL [local name]
   "annotation" MAY be added to the [children] or [attributes] of the <table> <value> element
   item.

   The translation of a TableConstraint that is a
   ComponentRelationConstraint is an  An element item with the same [local name]
   "table".  The (i.e., "attribute",
   "element", "component", "group" or "member") as the translation of
   the DefinedObjectSet NamedType corresponding to the identifier in the
   ComponentRelationConstraint ChoiceValue
   SHALL be added appended to the [children] or of the <value> element item.  An
   attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the <table> <attribute>, <element>, <component>, <group> or
   <member> element item.  The [normalized value] of this attribute item
   is a qualified name for the expanded name of the NamedType.  The
   translation of each
   AtNotation the Value in the ChoiceValue SHALL be appended added to the
   [children] or [attributes] of the <table> <attribute>, <element>,
   <component>, <group> or <member> element item.

   The translation of an AtNotation a SequenceValue or SetValue is an element item
   with the



Legg                      Expires 20 April 2007                [Page 55]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006 [local name] "restrictBy".  The [children] property of the
   <restrictBy> "value".  An element item is set with the [local name]
   "annotation" MAY be added to the sequence [children] of character items
   for the character string formed by <value> element
   item.  If the concatenation of zero, one SequenceValue or
   more "../" strings, one for SetValue has a ComponentValueList,
   then the translation of each Level NamedValue nested in the AtNotation (including
   the empty one), followed by a "/" (U+002F) separated list of
   ComponentValueList SHALL be appended to the RXER
   character data translations [children] of the effective names [RXEREI] of <value>
   element item in the order in which their corresponding NamedType
   instances identified by appear in the ComponentIdList identifiers.
   If definition of the governing type.

   The translation of a NamedType is subject to an ATTRIBUTE or ATTRIBUTE-REF encoding
   instruction, SequenceOfValue or subject to a COMPONENT-REF encoding instruction that
   references a top-level NamedType that SetOfValue is subject to an ATTRIBUTE
   encoding instruction, then the translation of element item
   with the effective name is
   prefixed [local name] "value".  An element item with the "@" (U+0040) character.  Leading and/or trailing
   white space character items [local name]
   "annotation" MAY be added to the [children] of the
   <restrictBy> <value> element
   item.  White space character items MAY be added
   immediately before and/or after any character item for the "/"
   character.

   Examples

      ERROR.&Type({Errors}{@severity,@...errorId})

      <type>
       <constrained>
        <type>
         <fromClass class="tns:ERROR" fieldName="Type"/>
        </type>
        <table objectset="tns:Errors">
         <restrictBy>severity</restrictBy>
         <restrictBy>../../../errorId</restrictBy>
        </table>
       </constrained>
      </type>

      SEQUENCE {
          iD     [RXER:NAME AS "ID"] [RXER:ATTRIBUTE]
                     TYPE-IDENTIFIER.&id({AllTypes}),
          value  TYPE-IDENTIFIER.&Type({AllTypes}{@iD})
      }

      <type>
       <sequence>
        <attribute name="ID">
         <type>
          <constrained>
           <type>
            <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="id"/>
           </type>
           <table objectset="tns:AllTypes"/>



Legg                      Expires 20 April 2007                [Page 56]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


          </constrained>
         </type>
        </attribute>
        <element name="value">
         <type>
          <constrained>
           <type>
            <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="Type"/>
           </type>
           <table objectset="tns:AllTypes">
            <restrictBy>@ID</restrictBy>
           </table>
          </constrained>
         </type>
        </element>
       </sequence>
      </type>

   The <restrictBy> element item is required to be self-contained
   [RXER].

      Aside: An element item is self-contained if all namespace prefixes
      used by the element item and its contents are declared within the
      element item.

6.13.4.  ContentsConstraint Translation

   The translation of a ContentsConstraint is an element item with the
   [local name] "contents".

   If the ContentsConstraint is of the "CONTAINING Type" form, SequenceOfValue or SetOfValue has a NamedValueList, then an
   element item with the [local name] "containing" SHALL be added to the
   [children] of the <contents> element item.  The
   translation of each NamedValue nested in the
   Type NamedValueList SHALL be added
   appended to the [children] or [attributes] of the
   <containing> <value> element item.

   If the ContentsConstraint is of the "ENCODED BY Value" form, SequenceOfValue or SetOfValue has a ValueList, then an element
   item with the same [local name] "encodedBy" SHALL be added to (i.e., "element" or "component") as
   the element item in the [children] of the <contents> <sequenceOf> or <setOf>
   element item.  The item in the translation of the
   Value governing type SHALL be added



Legg                      Expires 22 June 2007                 [Page 56]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   appended to the [children] or [attributes] of the
   <encodedBy> element item.

   If the ContentsConstraint is of the
   "CONTAINING Type ENCODED BY Value" form, then an <value> element item with for each Value
   nested in the [local name] "containing" and an element ValueList.  An attribute item with the [local name] "encodedBy" SHALL be added to the [children] of the
   <contents> element item.  The translation of the Type
   "name" and [normalized value] "item" SHALL be added to the [children] or
   [attributes] of the <containing> <element> or <component> element item.



Legg                      Expires 20 April 2007                [Page 57]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006  The
   translation of the Value (from the ValueList) SHALL be added to the
   [children] or [attributes] of the <encodedBy> <element> or <component> element
   item.

   Example

      OCTET STRING
          (CONTAINING MyType
           ENCODED BY { joint-iso-itu-t asn1(1) basic-encoding(1) })

      <type>
       <constrained type="asnx:OCTET-STRING">
        <contents>
         <containing type="tns:MyType/>
         <encodedBy literalValue="2.1.1"/>
        </contents>
       </constrained>
      </type>

6.13.5.  ExceptionSpec Translation

   The translation of an empty ExceptionSpec is empty.

   The translation of a non-empty ExceptionSpec NamedValue is an element item with the same
   [local name] "exception".

   If the ExceptionSpec is a SignedNumber, then the translation of a
   notional INTEGER Type and as the translation of a notional Value of the
   INTEGER type corresponding NamedType, i.e.,
   "attribute", "element", "component", "group", "item" or
   "simpleContent".  An attribute item with the IntegerValue of SignedNumber [local name] "name"
   SHALL be added to the [children] and/or [attributes] of the <exception> element item.

   If the ExceptionSpec is a DefinedValue, then the translation of a
   notional INTEGER Type and the translation of the DefinedValue SHALL
   be added to the [children] and/or [attributes]  The
   [normalized value] of the <exception>
   element item.

   If the ExceptionSpec this attribute item is of the "Type : Value" form, then a qualified name for the
   translation
   expanded name of the Type and the NamedType.  The translation of the Value in the
   NamedValue SHALL be added to the [children] and/or or [attributes] of the <exception>
   element item.

   Examples

      !10

      <exception type="asnx:INTEGER" literalValue="10"/>

      !myValue




Legg                      Expires 20 April 2007                [Page 58]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


      <exception type="asnx:INTEGER" value="tns:myValue"/>

      !PrintableString:"failure"

      <exception type="asnx:PrintableString" literalValue="failure"/>

7.  Translation of Values

   A Value in an ASN.1 specification

      -- This is a mix of literal values (e.g.,
   numbers and character strings) and notations for referencing defined
   values.  Likewise, the ASN.X translation of a Value is a mix of
   markup for literal values and markup for referencing notations
   (notational values).  A Value is categorized by the following
   definitions.

   Definition (literal value): A Value is a literal value if and only if
   it is not a notational value.

   Definition (notational value): A Value is a notational value if and
   only if:

   (a) the Value is a BuiltinValue, and

       (1) the BuiltinValue is a TaggedValue and the Value in the
           TaggedValue is a notational value, or

       (2) the BuiltinValue is a SequenceValue or SetValue and the
           ComponentValueList of the SequenceValue or SetValue contains
           a NamedValue where the translation of the corresponding
           NamedType (from the governing type of the Value) is not an
           <element> or <component> element item and the Value of the
           NamedValue is a notational value, or

       (3) the BuiltinValue is a ChoiceValue where the translation of
           the NamedType corresponding to the identifier of the
           ChoiceValue is not an <element> or <component> element item
           and the Value of the ChoiceValue is a notational value, or

       (4) the BuiltinValue is a SequenceOfValue with a NamedValueList
           that contains a NamedValue where the translation of the
           corresponding NamedType (from the governing type of the
           Value) is not an <element> or <component> element item and
           the Value of the NamedValue is a notational value, or

   (b) the Value is a ReferencedValue, and

       (1) the ReferencedValue is a ValueFromObject, or type.
      MyType ::= SEQUENCE {
           one    [ATTRIBUTE] INTEGER,
           two    INTEGER,
           three  [ATTRIBUTE][LIST] SEQUENCE OF number INTEGER
      }

      <namedType name="MyType">
       <type>
        <sequence>
         <attribute name="one" type="asnx:INTEGER"/>
         <element name="two" type="asnx:INTEGER"/>
         <attribute name="three">
          <type>
           <list>
            <item name="number" type="asnx:INTEGER"/>
           </list>
          </type>
         </attribute>
        </sequence>
       </type>
      </namedType>

      myValue1 MyType ::= {
          one     456,
          two     123,
          three   { number 123, number 456 }
      }



Legg                      Expires 20 April 22 June 2007                 [Page 59] 57]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


       (2) the ReferencedValue is a DefinedValue, and

           (i)   the DefinedValue is a valuereference (not a
                 DummyReference) or an ExternalValueReference, or

           (ii)  the DefinedValue is a DummyReference or
                 ParameterizedValue and the substitute definition for
                 the DummyReference or ParameterizedValue is a
                 notational value (see Section 5.9), or

           (iii) the DefinedValue is a DummyReference or
                 ParameterizedValue where the translation of the
                 DummyReference or ParameterizedValue will use a fully
                 expanded reference (see Section 5.9), or

   (c) the Value is an ObjectClassFieldValue, and

       (1) the ObjectClassFieldValue is an OpenTypeFieldVal, or

       (2) the ObjectClassFieldValue is a FixedTypeFieldVal, and

           (i)  the FixedTypeFieldVal is a BuiltinValue that satisfies
                case (a), or

           (ii) the FixedTypeFieldVal is a ReferencedValue that
                satisfies case (b).

   A literal value that is a BuiltinValue that is a SequenceValue,
   SetValue, ChoiceValue, SequenceOfValue or SetOfValue MAY be
   translated as a notational value.

   Definition (directly nested): A notational value is directly nested
   (within a literal value) if the innermost enclosing Value is a
   literal value.

7.1.  Translation of Literal Values

   The translation of a literal value is either the attribute form
   translation of a


      -- All literal value, or values.

      <namedValue name="myValue1" type="tns:MyType">
       <literalValue one="456" three="123 456">
        <two>123</two>
       </literalValue>
      </namedValue>

      myValue2 MyType ::= {
          one     456,
          two     myObject.&number,
            -- only the element form translation of a
   literal value.

   The attribute form translation of a literal value for component "two" is an attribute
   item with the [local name] "literalValue" whose [normalized value] is
   the RXER character data translation [RXER] of the Value.

   The attribute form translation of a literal notational value SHALL NOT be used
   if:
          three   { number 123, number 456 }
      }

      <namedValue name="myValue2" type="tns:MyType">
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule"
                     one="456" three="123 456">
        <two asnx:literal="false">
         <fromObjects object="tns:myObject" fieldName="number"/>
        </two>
       </literalValue>
      </namedValue>

      myValue3 MyType ::= {
          one     myObject.&number,
          two     123,
          three   { number 123, number myObject.&number }
      }

      <namedValue name="myValue3" type="tns:MyType">
       <value>
        <attribute name="one">
         <value>
          <fromObjects object="tns:myObject" fieldName="number"/>
         </value>
        </attribute>
        <element name="two" literalValue="123"/>
        <attribute name="three">
         <value>
          <item name="number" literalValue="123"/>
          <item name="number">
           <value>
            <fromObjects object="tns:myObject" fieldName="number"/>
           </value>
          </item>
         </value>



Legg                      Expires 20 April 22 June 2007                 [Page 60] 58]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   (a) the RXER Infoset translation of the Value is not a character data
       translation [RXER] or is a character data translation that
       contains qualified names [XMLNS10], or

   (b) attribute forms of Value have been explicitly disallowed, or

   (c) the Value has a nested notational value.


        </attribute>
       </value>
      </namedValue>

7.2.3.  ValueFromObject Translation

   The element form translation of a literal value ValueFromObject is an element item with the
   [local name] "literalValue" whose [children] and
   [attributes] are "value".  An element item with the RXER Infoset translation of [local name]
   "annotation" MAY be added to the Value, except
   that a value [children] of the EXTERNAL type (or a subtype thereof) is
   translated according to <value> element
   item.  An element item with the associated type defined in Clause 34.5 of
   X.680 [X.680].  In addition, where [local name] "fromObjects" SHALL be
   appended to the [children] and [attributes] of
   an element item in the <value> element item.

   The translation correspond to a directly nested
   notational value, of the translation specified ReferencedObjects instance in Section 7.2. MUST the
   ValueFromObject SHALL be
   used for added to the [children] and or [attributes] of that
   the <fromObjects> element item, and an
   attribute item with item.

   The translation of the [local name] "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and [normalized value] "false" or "0"
   (e.g., asnx:literal="false") MUST FieldName in the ValueFromObject SHALL be
   added to the [children] or [attributes] of
   that the <fromObjects> element
   item.

   Each outermost <literalValue> element item, and each nested element
   item that corresponds to

7.2.4.  ObjectClassFieldValue Translation

   If an ObjectClassFieldValue is a top-level NamedType from BuiltinValue in a module with FixedTypeFieldVal,
   then the translation of the ObjectClassFieldValue is the translation
   of the BuiltinValue.

   If an ObjectClassFieldValue is a
   target namespace, ReferencedValue in a
   FixedTypeFieldVal, then the translation of the ObjectClassFieldValue
   is required to be self-contained [RXER].

      Aside: An element item the translation of the ReferencedValue.

   If an ObjectClassFieldValue is self-contained if all namespace prefixes
      used by an OpenTypeFieldVal, then the element item and its contents are declared within
   translation of the
      element item.

      Aside: A <literalValue> element item nested within another
      <literalValue> ObjectClassFieldValue is an element item is not required to be self-contained. with the
   [local name] "value".  An attribute element item with the [local name] "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and [normalized value] "true" or "1"
   (e.g., asnx:literal="true")
   "annotation" MAY be added to the [attributes] [children] of the
   <literalValue> <value> element item and/or any nested
   item.  An element item whose
   content and attributes correspond with the [local name] "openTypeValue" SHALL be
   appended to a literal value.

      Aside: The asnx:literal attribute operates as a switch that
      indicates whether the content and other attributes [children] of the <value> element
      containing item.  The
   translation of the attribute are interpreted as ASN.X notation (a
      notational value) or as an RXER encoding (a literal value).

   From Type in the perspective of an ASN.X document as OpenTypeFieldVal SHALL be added to the RXER encoding
   [children] or [attributes] of an
   abstract value the <openTypeValue> element item.  The
   translation of the ModuleDefinition type Value in Appendix A, the type
   of the <literalValue> element is unconstrained Markup [RXER], not OpenTypeFieldVal SHALL be added to
   the
   governing type [children] or [attributes] of the Value.  This means that the Infoset <openTypeValue> element item.

   Example

      myValue TYPE-IDENTIFIER.&Type ::= INTEGER:123

      <namedValue name="myValue">
       <type>
        <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="Type"/>



Legg                      Expires 20 April 22 June 2007                 [Page 61] 59]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   representation of the <literalValue> element must be preserved in
   re-encodings


       </type>
       <value>
        <openTypeValue type="asnx:INTEGER" literalValue="123"/>
       </value>
      </namedValue>

8.  Translation of the ASN.X document.

   Similarly, the type Value Sets

   The translation of the literalValue attribute is a UTF8String,
   not ValueSet is an element item with the governing type of
   [local name] "valueSet".  An element item with the Value.  This means that [local name]
   "annotation" MAY be added to the exact
   characters [children] of the [normalized value] <valueSet> element
   item.  The translation of the attribute must be
   preserved ElementSetSpecs instance in re-encodings the
   ValueSet SHALL be appended to the [children] of the ASN.X document.

7.2. <valueSet>
   element item.

   Example

      { 1 | 3..7, ..., 9..19 EXCEPT ( 11 | 12 ) }

      <valueSet>
       <union>
        <literalValue>1</literalValue>
        <range>
         <minInclusive literalValue="3"/>
         <maxInclusive literalValue="7"/>
        </range>
       </union>
       <extension>
        <all>
         <range>
          <minInclusive literalValue="9"/>
          <maxInclusive literalValue="19"/>
         </range>
         <except>
          <union>
           <literalValue>11</literalValue>
           <literalValue>12</literalValue>
          </union>
         </except>
        </all>
       </extension>
      </valueSet>

8.1.  ElementSetSpecs Translation of Notational Values

   The translation of a notational value an ElementSetSpecs instance where the ellipsis
   ("...") is not present is the translation of either a
   BuiltinValue, a ReferencedValue or an ObjectClassFieldValue. the ElementSetSpec in
   the RootElementSetSpec.



Legg                      Expires 22 June 2007                 [Page 60]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   The translation of a ReferencedValue an ElementSetSpecs instance where the ellipsis
   ("...") is present is the translation of either a
   DefinedValue or a ValueFromObject.

   The translation for each these cases is described as creating the ElementSetSpec in the
   RootElementSetSpec followed by an element item with the [local name] "value", which
   "extension".  If an AdditionalElementSetSpec is appropriate for
   a notational value that stands on its own.  However, a notational
   value may also be directly nested within a literal value, present in which
   case the [local name] will
   ElementSetSpecs, then the translation of the ElementSetSpec in the
   AdditionalElementSetSpec SHALL be determined according added to RXER and the
   governing ASN.1 type [children] of the enclosing literal value.

      Aside: In
   <extension> element item.

8.2.  ElementSetSpec Translation

   If an ElementSetSpec is of the latter case "ALL Exclusions" form, then the
   translation of the ElementSetSpec is an element item will also have a
      literal attribute item with the [normalized value] "false" or "0".

   A notational value that is not directly nested within a literal value
   MAY instead have the
   [local name] "literalValue" provided an
   attribute "all".  An element item with the [local name] "literal", [namespace name]
   "urn:ietf:params:xml:ns:asnx" and [normalized value] "false" or "0"
   is "except"
   SHALL be added to the [attributes] [children] of the <literalValue> <all> element item.  The
   translation of the Elements instance in the Exclusions SHALL be added
   to the [children] of the <except> element item.

   Examples

      zero INTEGER ::= 0

      <namedValue name="zero" type="asnx:INTEGER" literalValue="0"/>

          OR

      <namedValue name="zero" type="asnx:INTEGER">
       <literalValue>0</literalValue>
      </namedValue>

      nothing INTEGER ::= zero

      <namedValue name="nothing" type="asnx:INTEGER" value="tns:zero"/>




Legg                      Expires 20 April 2007                [Page 62]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


          OR

      <namedValue name="nothing" type="asnx:INTEGER">
       <value ref="tns:zero"/><!-- A notational value. -->
      </namedValue>

          OR

      <namedValue name="nothing" type="asnx:INTEGER">
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule"
                     asnx:literal="false"
                     ref="tns:zero"/><!-- A notational value. -->
      </namedValue>

      integerList SEQUENCE OF number INTEGER ::= { zero, 3, 7 }

      <namedValue name="integerList">
       <type>
        <sequenceOf>
         <element name="number" type="asnx:INTEGER"/>
        </sequenceOf>
       </type>
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule">
        <number asnx:literal="false"
                ref="tns:zero"/><!-- A notational value. -->
        <number>3</number><!-- A literal value. -->
        <number>7</number><!-- A literal value. -->
       </literalValue>
      </namedValue>

7.2.1.  DefinedValue Translation

   If a DefinedValue an ElementSetSpec is a valuereference (not a DummyReference) or an
   ExternalValueReference, Unions instance, then the translation of
   the DefinedValue ElementSetSpec is
   either the attribute form translation of the Unions instance.

   If a value reference, or Unions instance has only one nested Intersections instance, then
   the
   element form translation of a value reference.

   The attribute form the Unions instance is the translation of a value reference that
   Intersections instance, otherwise the translation of the Unions
   instance is an attribute element item with the [local name] "value".  The [normalized value] of this
   attribute item is "union".  In the qualified name referencing
   latter case, the value definition
   (see Section 5.1).  The attribute form translation of each nested Intersections instance
   SHALL NOT be used
   if appended to the qualified name is shared by two or more value definitions in
   separate modules, i.e., is ambiguous.

   The [children] of the <union> element form item.

   If an Intersections instance has only one nested IntersectionElements
   instance, then the translation of a value reference the Intersections instance is the
   translation of that IntersectionElements instance, otherwise the
   translation of the Intersections instance is an element item with the
   [local name] "value".  An attribute item with "intersection".  In the



Legg                      Expires 20 April 2007                [Page 63]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   [local name] "ref" latter case, the translation of
   each nested IntersectionElements instance SHALL be added appended to the [attributes]
   [children] of the <value> <intersection> element item.  The [normalized value] of this attribute item is the
   qualified name referencing the value definition (see Section 5.1).

   If this reference name an IntersectionElements instance is not distinct with respect to the current
   module and of the modules referenced by its <import> element items (see
   Section 5.1), "Elems Exclusions"
   form, then the translation of the IntersectionElements instance is an attribute
   element item with the [local name] "context" "all".  The translation of the
   Elements instance in the Elems SHALL be added to the [attributes] [children] of
   the <value> <all> element item.  An element item,
   otherwise if the module containing the referenced value definition
   has a schema identity URI, then an attribute item with the [local name] "context" MAY
   "except" SHALL be added appended to the [attributes] [children] of the
   <value> <all> element
   item.  The [normalized value] of this attribute item
   is the schema identity URI translation of the module containing the value
   definition referenced by the DefinedValue.

      Aside: If a reference name is not distinct, then the module
      containing the referenced definition must have a schema identity
      URI (see Section 5.1).

   An element item with Elements instance in the [local name] "annotation" MAY Exclusions
   SHALL be added to the [children] of the <value> <except> element item.

   Usually

   If an IntersectionElements instance is an Elements instance, then the translator
   translation of the IntersectionElements instance is free to choose either the translation
   of the Elements instance.




Legg                      Expires 22 June 2007                 [Page 61]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   The translation of an attribute form or
   element form Elements instance is the translation for a DefinedValue, however of the
   SubtypeElements, ObjectSetElements or ElementSetSpec in some contexts
   attribute forms the Elements
   instance.

8.3.  SubtypeElements Translation

   If a SubtypeElements instance is a SingleValue, then the translation
   of the SubtypeElements instance is the translation of the Value are explicitly disallowed.  In particular, in
   the SingleValue, except that an attribute form of the Value
   translation SHALL NOT be used for a DefinedValue
   that is directly nested in a literal value. used.

   If a DefinedValue SubtypeElements instance is a DummyReference or ParameterizedValue, ContainedSubtype, then the
   translation of the DefinedValue SubtypeElements instance is an element item with
   the translation of that
   DummyReference or ParameterizedValue (see Section 5.9).

7.2.2.  BuiltinValue Translation [local name] "includes".  The translation of a BuiltinValue is the translation of either a
   ChoiceValue, a SequenceValue, a SequenceOfValue, a SetValue or a
   TaggedValue.

      Aside: There are other possibilities for a BuiltinValue, but these
      will all Type in the
   ContainedSubtype SHALL be literal values.  This section applies added to the [children] or [attributes] of
   the <includes> element item.

   If a
      BuiltinValue that SubtypeElements instance is a notational value.

   The ValueRange, then the translation
   of a TaggedValue the SubtypeElements instance is the translation of the contained
   Value (which ValueRange.

   If a SubtypeElements instance is necessarily a notational value).

   The SizeConstraint, then the
   translation of a ChoiceValue the SubtypeElements instance is an element item with
   the [local name] "value".  An element item with "size".  The translation of the [local name]
   "annotation" MAY Constraint in the
   SizeConstraint SHALL be added to the [children] of the <value> <size> element
   item.  An

   If a SubtypeElements instance is a TypeConstraint, then the
   translation of the SubtypeElements instance is an element item with
   the same [local name] (i.e., "attribute",



Legg                      Expires 20 April 2007                [Page 64]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   "element", "group" or "member") as the "typeConstraint".  The translation of the NamedType
   corresponding to the identifier Type in
   the ChoiceValue TypeConstraint SHALL be appended added to the [children] or [attributes]
   of the <value> <typeConstraint> element item.  An attribute

   If a SubtypeElements instance is a PermittedAlphabet, then the
   translation of the SubtypeElements instance is an element item with
   the [local name] "name" "from".  The translation of the Constraint in the
   PermittedAlphabet SHALL be added to the [attributes] [children] of the <attribute>, <element>, <component>, <group> or <member> <from>
   element item.  The [normalized value]

   If a SubtypeElements instance is an InnerTypeConstraints instance,
   then the translation of this attribute item the SubtypeElements instance is the RXER
   character data
   translation of the effective name InnerTypeConstraints instance.

   If a SubtypeElements instance is a PatternConstraint, then the
   translation of the NamedType. SubtypeElements instance is an element item with
   the [local name] "pattern".  The translation of the Value in the ChoiceValue
   PatternConstraint SHALL be added to the [children] or [attributes] of
   the <attribute>, <element>,
   <component>, <group> or <member> <pattern> element item.




Legg                      Expires 22 June 2007                 [Page 62]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


8.3.1.  ValueRange Translation

   The translation of a SequenceValue or SetValue ValueRange is an element item with the
   [local name] "value".  An "range".

   If the LowerEndpoint in the ValueRange is of the "LowerEndValue <"
   form, then an element item with the [local name]
   "annotation" MAY "minExclusive" SHALL
   be added to the [children] of the <value> <range> element item.  The translation of each NamedValue in  If the ComponentValueList
   LowerEndValue is a Value, then the translation of the SequenceValue or SetValue Value SHALL be appended
   added to the [children] or [attributes] of the <value> <minExclusive> element item, in
   item.

   If the order in which their
   corresponding NamedType instances appear LowerEndpoint in the definition ValueRange is of the
   governing type.

   The translation of a SequenceOfValue "LowerEndValue" form
   and the LowerEndValue is a Value, then an element item with the
   [local name] "value".  An element item with the [local name]
   "annotation" MAY "minInclusive" SHALL be added to the [children] of the <value>
   <range> element item.

   If the SequenceOfValue has a NamedValueList, then the  The translation of
   each NamedValue the Value in the NamedValueList
   LowerEndValue SHALL be appended added to the [children] or [attributes] of the <value>
   <minInclusive> element item.

   If the SequenceOfValue has a ValueList, LowerEndpoint in the ValueRange is of the "LowerEndValue" form
   and the LowerEndValue is "MIN", then an element item with the
   [local name] "element" or "component" (translator's choice) SHALL "minInclusive" MAY be
   appended added to the [children] of the <value>
   <range> element item for each Value item.

   If the UpperEndpoint in the ValueList.  An attribute ValueRange is of the "< UpperEndValue"
   form, then an element item with the [local name] "name" and
   [normalized value] "item" "maxExclusive" SHALL
   be added to the [attributes] [children] of the
   <element> or <component> <range> element item.  The  If the
   UpperEndValue is a Value, then the translation of the Value
   (from the ValueList) SHALL be
   added to the [children] or [attributes] of the <element> or <component> <maxExclusive> element
   item.

   The translation of a NamedValue is an element item with

   If the same
   [local name] as UpperEndpoint in the translation ValueRange is of the corresponding NamedType, i.e.,
   "attribute", "element", "group" or "item".  An attribute "UpperEndValue" form
   and the UpperEndValue is a Value, then an element item with the
   [local name] "name" "maxInclusive" SHALL be added to the [attributes] [children] of the
   <range> element item.  The [normalized value] of this attribute item is the
   RXER character data translation of the effective name of the
   NamedType.  The translation of the Value in the NamedValue
   UpperEndValue SHALL be added to the [children] or [attributes] of the
   <maxInclusive> element item.

   Examples



Legg                      Expires 20 April 2007                [Page 65]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


      -- This

   If the UpperEndpoint in the ValueRange is of the governing type.
      MyType ::= SEQUENCE {
           one    [ATTRIBUTE] INTEGER,
           two    INTEGER,
           three  [ATTRIBUTE][LIST] SEQUENCE OF number INTEGER
      }

      <namedType name="MyType">
       <type>
        <sequence>
         <attribute name="one" type="asnx:INTEGER"/>
         <element name="two" type="asnx:INTEGER"/>
         <attribute name="three">
          <type>
           <list>
            <item name="number" type="asnx:INTEGER"/>
           </list>
          </type>
         </attribute>
        </sequence>
       </type>
      </namedType>

      myValue1 MyType ::= {
          one     456,
          two     123,
          three   { number 123, number 456 }
      }
      -- All literal values.

      <namedValue name="myValue1" type="tns:MyType">
       <literalValue one="456" three="123 456">
        <two>123</two>
       </literalValue>
      </namedValue>

      myValue2 MyType ::= {
          one     456,
          two     myObject.&number,
            -- only "UpperEndValue" form
   and the value for component "two" UpperEndValue is a notational value
          three   { number 123, number 456 }
      }

      <namedValue name="myValue2" type="tns:MyType">
       <literalValue xmlns:asnx="urn:ietf:params:xml:ns:asnx"
                     xmlns:tns="http://example.com/ns/MyModule"
                     one="456" three="123 456">
        <two asnx:literal="false">



Legg                      Expires 20 April 2007                [Page 66]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


         <fromObjects object="tns:myObject" fieldName="number"/>
        </two>
       </literalValue>
      </namedValue>

      myValue3 MyType ::= {
          one     myObject.&number,
          two     123,
          three   { number 123, number myObject.&number }
      }

      <namedValue name="myValue3" type="tns:MyType">
       <value>
        <attribute name="one">
         <value>
          <fromObjects object="tns:myObject" fieldName="number"/>
         </value>
        </attribute>
        <element name="two" literalValue="123"/>
        <attribute name="three">
         <value>
          <item name="number" literalValue="123"/>
          <item name="number">
           <value>
            <fromObjects object="tns:myObject" fieldName="number"/>
           </value>
          </item>
         </value>
        </attribute>
       </value>
      </namedValue>

7.2.3.  ValueFromObject "MAX", then an element item with the
   [local name] "maxInclusive" MAY be added to the [children] of the
   <range> element item.

   Examples

      1..10

      <range>



Legg                      Expires 22 June 2007                 [Page 63]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


       <minInclusive literalValue="1"/>
       <maxInclusive literalValue="10"/>
      </range>

      0..MAX

      <range>
       <minInclusive literalValue="0"/>
      </range>

      0<..<MAX

      <range>
       <minExclusive literalValue="0"/>
       <maxExclusive/>
      </range>

8.3.2.  InnerTypeConstraints Translation

   The translation of an InnerTypeConstraints instance that has a ValueFromObject
   SingleTypeConstraint is an element item with the [local name] "value".  An
   "withComponent".  The translation of the Constraint in the
   SingleTypeConstraint SHALL be added to the [children] of the
   <withComponent> element item.

   The translation of an InnerTypeConstraints instance that has a
   MultipleTypeConstraints instance is an element item with the
   [local name]
   "annotation" MAY "withComponents".  If the MultipleTypeConstraints
   instance is a PartialSpecification, then an attribute item with the
   [local name] "partial" and the [normalized value] "true" or "1" SHALL
   be added to the [children] [attributes] of the <value> <withComponents> element item.  An element
   If the MultipleTypeConstraints instance is a FullSpecification, then
   an attribute item with the [local name] "fromObjects" "partial" and the
   [normalized value] "false" or "0" MAY be added to the [attributes] of
   the <withComponents> element item.  The translation of each
   NamedConstraint nested in the TypeConstraints instance in the
   FullSpecification or PartialSpecification SHALL be appended to the
   [children] of the <value> <withComponents> element item.

   The translation of a NamedConstraint is an element item with the ReferencedObjects in the ValueFromObject and same
   [local name] (i.e., "attribute", "element", "component", "group",
   "member" or "simpleContent") as the translation of the FieldName NamedType
   corresponding to the identifier in the ValueFromObject NamedConstraint.  An attribute
   item with the [local name] "name" SHALL be added to the [children] and/or [attributes]
   of the <fromObjects> <attribute>, <element>, <component>, <group>, <member> or
   <simpleContent> element item.

7.2.4.  ObjectClassFieldValue Translation

   If an ObjectClassFieldValue  The [normalized value] of this
   attribute item is a BuiltinValue qualified name for the expanded name of the
   NamedType corresponding to the identifier in a FixedTypeFieldVal, the NamedConstraint.



Legg                      Expires 20 April 22 June 2007                 [Page 67] 64]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   If the PresenceConstraint in the ComponentConstraint in the
   NamedConstraint is not empty, then an attribute item with the translation
   [local name] "use" SHALL be added to the [attributes] of the ObjectClassFieldValue
   <attribute>, <element>, <component>, <group>, <member> or
   <simpleContent> element item.  The [normalized value] of this
   attribute item is the translation text of the BuiltinValue. PresenceConstraint with all letters
   downcased, i.e., either "present", "absent" or "optional".

   If the ValueConstraint in the ComponentConstraint in the
   NamedConstraint is not empty, then the translation of the Constraint
   in the ValueConstraint SHALL be added to the [children] of the
   <attribute>, <element>, <component>, <group>, <member> or
   <simpleContent> element item.

9.  Translation of Object Classes

   The translation of an ObjectClassFieldValue ObjectClass is the translation of the
   DefinedObjectClass, ObjectClassDefn or ParameterizedObjectClass in
   the ObjectClass.

   The translation of a ReferencedValue ParameterizedObjectClass is described in
   Section 13.

9.1.  DefinedObjectClass Translation

   If a
   FixedTypeFieldVal, DefinedObjectClass is an objectclassreference (not a
   DummyReference), an ExternalObjectClassReference or a
   UsefulObjectClassReference, then the translation of the ObjectClassFieldValue
   DefinedObjectClass is either the attribute form translation of an
   object class reference, or the element form translation of an object
   class reference.

   The attribute form translation of an object class reference is an
   attribute item with the [local name] "class".  The [normalized value]
   of this attribute item is a qualified name for the expanded name of
   the referenced object class definition (see Section 5.1).  In the
   case of a UsefulObjectClassReference, the namespace name of the
   expanded name is "urn:ietf:params:xml:ns:asnx" and the local name is
   either "TYPE-IDENTIFIER" or "ABSTRACT-SYNTAX", as the case may be.
   The attribute form translation SHALL NOT be used if the expanded name
   is not distinct with respect to the current module and the modules
   referenced by its <import> element items (see Section 5.1).
   Otherwise, the translator is free to choose either the attribute form
   or element form translation of the ReferencedValue.

   If an ObjectClassFieldValue is for an OpenTypeFieldVal, then the object class reference.

   The element form translation of the ObjectClassFieldValue an object class reference is an
   element item with the [local name] "value". "class".  An element item with the
   [local name] "annotation" MAY be added to the [children] of the <value>



Legg                      Expires 22 June 2007                 [Page 65]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   <class> element item.  An element attribute item with the [local name] "openTypeValue" "ref"
   SHALL be
   appended added to the [children] [attributes] of the <value> <class> element item.  The
   translation
   [normalized value] of this attribute item is a qualified name for the Type in
   expanded name of the OpenTypeFieldVal and referenced object class definition.  In the translation case
   of a UsefulObjectClassReference, the Value in namespace name of the OpenTypeFieldVal SHALL be added expanded
   name is "urn:ietf:params:xml:ns:asnx" and the local name is either
   "TYPE-IDENTIFIER" or "ABSTRACT-SYNTAX", as the case may be.  If the
   expanded name is not distinct with respect to the [children]
   and/or [attributes] of current module and
   the <openTypeValue> modules referenced by its <import> element item.

   Example

      myValue TYPE-IDENTIFIER.&Type ::= INTEGER:123

      <namedValue name="myValue">
       <type>
        <fromClass class="asnx:TYPE-IDENTIFIER" fieldName="Type"/>
       </type>
       <value>
        <openTypeValue type="asnx:INTEGER" literalValue="123"/>
       </value>
      </namedValue>

8.  Translation of Value Sets

   The translation of a ValueSet is items, then an element
   attribute item with the [local name] "valueSet".  An "context" SHALL be added to the
   [attributes] of the <class> element item, otherwise if the module
   containing the referenced object class definition has a schema
   identity URI, then an attribute item with the [local name]
   "annotation" "context"
   MAY be added to the [children] [attributes] of the <valueSet> <class> element item.  The translation
   [normalized value] of this attribute item is the ElementSetSpecs in the ValueSet SHALL
   be appended to the [children] schema identity URI
   of the <valueSet> element item.

   Example

      { 1 | 3..7, ..., 9..19 EXCEPT ( 11 | 12 ) }

      <valueSet>
       <union>
        <literalValue>1</literalValue>
        <range>
         <minInclusive literalValue="3"/>
         <maxInclusive literalValue="7"/>



Legg                      Expires 20 April 2007                [Page 68]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


        </range>
       </union>
       <extension>
        <all>
         <range>
          <minInclusive literalValue="9"/>
          <maxInclusive literalValue="19"/>
         </range>
         <except>
          <union>
           <literalValue>11</literalValue>
           <literalValue>12</literalValue>
          </union>
         </except>
        </all>
       </extension>
      </valueSet>

8.1.  ElementSetSpecs Translation

   The translation of an ElementSetSpecs where module containing the ellipsis ("...") referenced object class definition.

      Aside: If a reference name is not present is the translation of distinct, then the ElementSetSpec in module
      containing the
   RootElementSetSpec. referenced definition must have a schema identity
      URI (see Section 5.1).

   The translation of an ElementSetSpecs where the ellipsis ("...") is
   present DefinedObjectClass is the translation of the ElementSetSpec in same whether the
   RootElementSetSpec followed
   object class definition is referenced by an element item with the [local name]
   "extension".  If objectclassreference or
   an AdditionalElementSetSpec ExternalObjectClassReference.

   If a DefinedObjectClass is present, a DummyReference, then the translation of
   the ElementSetSpec in the AdditionalElementSetSpec
   SHALL be added to DefinedObjectClass is the [children] translation of the <extension> element item.

8.2.  ElementSetSpec DummyReference (see
   Section 13).

9.2.  ObjectClassDefn Translation

   If the ElementSetSpec is of the "ALL Exclusions" form, then the

   The translation of the ElementSetSpec an ObjectClassDefn is an element item with the
   [local name] "all". "class".  An element item with the [local name] "except"
   SHALL
   "annotation" MAY be added to the [children] of the <all> <class> element
   item.  The translation of the Elements each FieldSpec in the Exclusions ObjectClassDefn SHALL
   be added appended to the [children] of the <except> <class> element item.

   If the ElementSetSpec is of the "Unions" form, then the

   The translation of the ElementSetSpec a FieldSpec is the translation of the Unions.

   If the Unions has only one Intersections, then
   TypeFieldSpec, FixedTypeValueFieldSpec, VariableTypeValueFieldSpec,
   FixedTypeValueSetFieldSpec, VariableTypeValueSetFieldSpec,
   ObjectFieldSpec or ObjectSetFieldSpec in the FieldSpec.

9.2.1.  TypeFieldSpec Translation

   The translation of a TypeFieldSpec where the
   Unions TypeOptionalitySpec is the translation of that Intersections, otherwise the
   translation of the Unions
   absent is an element item with the [local name]
   "union". "typeField".

   The translation of each Intersections SHALL be appended to
   the [children] a TypeFieldSpec with a TypeOptionalitySpec of the <union> element item.



Legg                      Expires 20 April 22 June 2007                 [Page 69] 66]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   If the Intersections has only one IntersectionElements, then the
   translation of the Intersections is the translation of that
   IntersectionElements, otherwise the translation of the Intersections


   "OPTIONAL" form is an element item with the [local name] "intersection".  The
   translation of each IntersectionElements "optional".
   An element item with the [local name] "typeField" SHALL be appended added to
   the [children] of the <intersection> <optional> element item.

   If the IntersectionElements is of the "Elems Exclusions" form, then
   the

   The translation of a TypeFieldSpec with a TypeOptionalitySpec of the IntersectionElements
   "DEFAULT Type" form is an element item with the [local name] "all".  The translation of
   "optional".  An element item with the Elements in [local name] "typeField" SHALL
   be added to the Elems
   and an [children] of the <optional> element item.  An
   element item with the [local name] "except" "default" SHALL be added appended to the
   [children] of the <all> <optional> element item.  The translation of the
   Elements
   Type in the Exclusions TypeOptionalitySpec SHALL be added to the [children] or
   [attributes] of the
   <except> <default> element item.

   If the IntersectionElements is of the "Elements" form, then the
   translation of

   An attribute item with the IntersectionElements is [local name] "name" SHALL be added to the translation
   [attributes] of the
   Elements. <typeField> element item.  The translation [normalized value]
   of an Elements this attribute item is the translation of typefieldreference in the
   SubtypeElements, ObjectSetElements or ElementSetSpec, as appropriate.

8.3.  SubtypeElements Translation

   If a SubtypeElements is a SingleValue, then
   TypeFieldSpec, without the translation of ampersand character ('&', U+0026).  An
   element item with the
   SubtypeElements is [local name] "annotation" MAY be added to the
   [children] of the <typeField> element item.

   Example

      CLASS {
          &One,
          &Two    OPTIONAL,
          &Three  DEFAULT OBJECT IDENTIFIER
      }

      <class>
       <typeField name="One"/>
       <optional>
        <typeField name="Two"/>
       </optional>
       <optional>
        <typeField name="Three"/>
        <default type="asnx:OBJECT-IDENTIFIER"/>
       </optional>
      </class>

9.2.2.  FixedTypeValueFieldSpec Translation

   The translation of a FixedTypeValueFieldSpec where the Value, except that
   ValueOptionalitySpec is absent is an
   attribute form of element item with the Value
   [local name] "valueField".

   The translation SHALL NOT be used.

   If of a SubtypeElements is FixedTypeValueFieldSpec with a ContainedSubtype, then the translation
   ValueOptionalitySpec of the SubtypeElements "OPTIONAL" form is an element item with
   the [local name]
   "includes".  The translation of the Type in "optional".  An element item with the ContainedSubtype [local name]



Legg                      Expires 22 June 2007                 [Page 67]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   "valueField" SHALL be added to the [children] or [attributes] of the <includes> <optional>
   element item.

   If a SubtypeElements is a ValueRange, then the translation of the
   SubtypeElements is the

   The translation of the ValueRange.

   If a SubtypeElements is FixedTypeValueFieldSpec with a SizeConstraint, then the translation
   ValueOptionalitySpec of the
   SubtypeElements "DEFAULT Value" form is an element item
   with the [local name] "size".  The
   translation of the Constraint in "optional".  An element item with the SizeConstraint
   [local name] "valueField" SHALL be added to the [children] of the <size>
   <optional> element item.

   If a SubtypeElements is a TypeConstraint, then the translation of the
   SubtypeElements is an  An element item with the [local name]
   "typeConstraint".
   "default" SHALL be appended to the [children] of the <optional>
   element item.  The translation of the Type Value in the TypeConstraint
   ValueOptionalitySpec SHALL be added to the [children] or [attributes]
   of the
   <typeConstraint> <default> element item.




Legg                      Expires 20 April 2007                [Page 70]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006

   An attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the <valueField> element item.  The
   [normalized value] of this attribute item is the valuefieldreference
   in the FixedTypeValueFieldSpec, without the ampersand character ('&',
   U+0026).  If a SubtypeElements the "UNIQUE" keyword is a PermittedAlphabet, present, then an attribute item
   with the translation [local name] "unique" and [normalized value] "true" or "1"
   SHALL be added to the [attributes] of the SubtypeElements is <valueField> element item,
   otherwise an attribute item with the [local name] "unique" and
   [normalized value] "false" or "0" MAY be added to the [attributes] of
   the <valueField> element item.  An element item with the [local name] "from".
   "annotation" MAY be added to the [children] of the <valueField>
   element item.  The translation of the Constraint Type in the PermittedAlphabet
   FixedTypeValueFieldSpec SHALL be added to the [children] or
   [attributes] of the <from> <valueField> element item.

   If a SubtypeElements is an InnerTypeConstraints, then the

   Example

      CLASS {
          &one    OBJECT IDENTIFIER UNIQUE,
          &two    BOOLEAN OPTIONAL,
          &three  INTEGER DEFAULT 0
      }

      <class>
       <valueField name="one" unique="true"
                   type="asnx:OBJECT-IDENTIFIER"/>
       <optional>
        <valueField name="two" type="asnx:BOOLEAN"/>
       </optional>
       <optional>
        <valueField name="three" type="asnx:INTEGER"/>
        <default literalValue="0"/>
       </optional>
      </class>




Legg                      Expires 22 June 2007                 [Page 68]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


9.2.3.  FixedTypeValueSetFieldSpec Translation

   The translation of a FixedTypeValueSetFieldSpec where the SubtypeElements
   ValueSetOptionalitySpec is absent is an element item with the
   [local name] "valueSetField".

   The translation of the
   InnerTypeConstraints.

   If a SubtypeElements is FixedTypeValueSetFieldSpec with a PatternConstraint, then the translation
   ValueSetOptionalitySpec of the SubtypeElements "OPTIONAL" form is an element item
   with the [local name]
   "pattern".  The translation of the Value in "optional".  An element item with the PatternConstraint
   [local name] "valueSetField" SHALL be added to the [children] or [attributes] of the <pattern>
   <optional> element item.

8.3.1.  ValueRange Translation

   The translation of a ValueRange FixedTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of the "DEFAULT ValueSet" form is an element
   item with the [local name] "range".

   If the LowerEndpoint in the ValueRange is of the "LowerEndValue <"
   form, then an "optional".  An element item with the
   [local name] "minExclusive" SHALL
   be added to the [children] of the <range> element item.  If the
   LowerEndValue is not "MIN", then the translation of the Value in the
   LowerEndValue "valueSetField" SHALL be added to the [children] or [attributes] of the
   <minExclusive>
   <optional> element item.

   If the LowerEndpoint in the ValueRange is of the "LowerEndValue" form
   and the LowerEndValue is not "MIN", then an  An element item with the [local name] "minInclusive"
   "default" SHALL be added appended to the [children] of the
   <range> <optional>
   element item.  The translation of the Value ValueSet in the
   LowerEndValue
   ValueSetOptionalitySpec SHALL be added to the [children] or [attributes] of the
   <minInclusive>
   <default> element item.

   If the LowerEndpoint in the ValueRange is of the "LowerEndValue" form
   and the LowerEndValue is "MIN", then an element

   An attribute item with the [local name] "minInclusive" MAY "name" SHALL be added to the [children]
   [attributes] of the
   <range> <valueSetField> element item.

   If  The
   [normalized value] of this attribute item is the UpperEndpoint
   valuesetfieldreference in the ValueRange is of FixedTypeValueSetFieldSpec, without the "< UpperEndValue"
   form, then an
   ampersand character ('&', U+0026).  An element item with the
   [local name] "maxExclusive" SHALL "annotation" MAY be added to the [children] of the <range>
   <valueSetField> element item.  If the
   UpperEndValue is not "MAX", then the  The translation of the Value Type in the
   UpperEndValue
   FixedTypeValueSetFieldSpec SHALL be added to the [children] or
   [attributes] of the
   <maxExclusive> <valueSetField> element item.

   If the UpperEndpoint in the ValueRange is of the "UpperEndValue" form
   and the UpperEndValue is not "MAX", then an element item with the

   Example

      CLASS {
          &One    UTF8String,
          &Two    BOOLEAN OPTIONAL,
          &Three  INTEGER DEFAULT { 1 | 2 }
      }

      <class>
       <valueSetField name="One" type="asnx:UTF8String"/>
       <optional>
        <valueSetField name="Two" type="asnx:BOOLEAN"/>
       </optional>
       <optional>
        <valueSetField name="Three" type="asnx:INTEGER"/>
        <default>



Legg                      Expires 20 April 22 June 2007                 [Page 71] 69]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   [local name] "maxInclusive" SHALL be added to the [children] of the
   <range> element item.


         <valueSet>
          <union>
           <literalValue>1</literalValue>
           <literalValue>2</literalValue>
          </union>
         </valueSet>
        </default>
       </optional>
      </class>

9.2.4.  VariableTypeValueFieldSpec Translation

   The translation of a VariableTypeValueFieldSpec where the Value in the
   UpperEndValue SHALL be added to the [children] or [attributes] of the
   <maxInclusive> element item.

   If the UpperEndpoint in the ValueRange
   ValueOptionalitySpec is of the "UpperEndValue" form
   and the UpperEndValue absent is "MAX", then an element item with the
   [local name] "maxInclusive" MAY be added to the [children] of the
   <range> element item.

   Examples

      1..10

      <range>
       <minInclusive literalValue="1"/>
       <maxInclusive literalValue="10"/>
      </range>

      0..MAX

      <range>
       <minInclusive literalValue="0"/>
      </range>

      0<..<MAX

      <range>
       <minExclusive literalValue="0"/>
       <maxExclusive/>
      </range>

8.3.2.  InnerTypeConstraints Translation "valueField".

   The translation of an InnerTypeConstraints a VariableTypeValueFieldSpec with a
   ValueOptionalitySpec of the
   "WITH COMPONENT SingleTypeConstraint" "OPTIONAL" form is an element item with
   the [local name] "withComponent".  The translation of the Constraint
   in "optional".  An element item with the SingleTypeConstraint [local name]
   "valueField" SHALL be added to the [children] of the
   <withComponent> <optional>
   element item.

   The translation of an InnerTypeConstraints a VariableTypeValueFieldSpec with a
   ValueOptionalitySpec of the
   "WITH COMPONENTS MultipleTypeConstraints" "DEFAULT Value" form is an element item
   with the [local name] "withComponents".

   If the MultipleTypeConstraints is a PartialSpecification, then an
   attribute item with the [local name] "partial" and the
   [normalized value] "true" or "1" SHALL be added to the [attributes]
   of the <withComponents> "optional".  An element item.  If the MultipleTypeConstraints



Legg                      Expires 20 April 2007                [Page 72]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


   is a FullSpecification, then an attribute item with the
   [local name]
   "partial" and the [normalized value] "false" or "0" MAY be added to
   the [attributes] of the <withComponents> element item.

   The translation of each NamedConstraint in the
   MultipleTypeConstraints "valueField" SHALL be appended added to the [children] of the
   <withComponents>
   <optional> element item.

   The translation of a NamedConstraint is an  An element item with the same [local name] (i.e., "component", "attribute", "element", "group" or
   "member") as
   "default" SHALL be appended to the [children] of the <optional>
   element item.  The translation of the NamedType corresponding Value in the
   ValueOptionalitySpec SHALL be added to the
   identifier [children] or [attributes]
   of the NamedConstraint. <default> element item.

   An attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the
   <attribute>, <element>, <component>, <group> or <member> <valueField> element
   item, as the case may be. item.  The
   [normalized value] of this attribute item is the RXER character data translation of the effective name of
   the NamedType corresponding to the identifier of the NamedConstraint.

   If the PresenceConstraint of valuefieldreference
   in the ComponentConstraint of VariableTypeValueFieldSpec, without the
   NamedConstraint is not empty, then an attribute ampersand character
   ('&', U+0026).  An element item with the [local name] "use" SHALL "annotation"
   MAY be added to the [attributes] [children] of the
   <attribute>, <element>, <component>, <group> or <member> <valueField> element item.  An
   element
   item, as the case may be.  The [normalized value] of this attribute item is the text of the PresenceConstraint with all letters
   downcased, i.e., either "present", "absent" or "optional".

   If the ValueConstraint in the ComponentConstraint of the
   NamedConstraint is not empty, then the translation of the Constraint
   in the ValueConstraint [local name] "typeFromField" SHALL be added appended
   to the [children] of the
   <attribute>, <element>, <component>, <group> or <member> <valueField> element
   item, as the case may be.

9.  Translation of Object Classes item.  The translation
   of an ObjectClass is the translation of either a
   DefinedObjectClass, an ObjectClassDefn or a ParameterizedObjectClass.

   The translation of a ParameterizedObjectClass is described FieldName in
   Section 5.9.

9.1.  DefinedObjectClass Translation

   If a DefinedObjectClass is an objectclassreference (not a
   DummyReference), an ExternalObjectClassReference or a
   UsefulObjectClassReference, then the translation of the
   DefinedObjectClass is either VariableTypeValueFieldSpec SHALL be added to
   the attribute form translation of an
   object class reference, [children] or [attributes] of the <typeFromField> element form translation of an object
   class reference. item.

   Example

      CLASS {
          &Syntax DEFAULT INTEGER,
          &one    &Syntax,



Legg                      Expires 20 April 22 June 2007                 [Page 73] 70]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


          &two    &Syntax OPTIONAL,
          &three  &Syntax DEFAULT 0
      }

      <class>
       <optional>
        <typeField name="Syntax"/>
        <default type="asnx:INTEGER"/>
       </optional>
       <valueField name="one">
        <typeFromField fieldName="Syntax"/>
       </valueField>
       <optional>
        <valueField name="two">
         <typeFromField fieldName="Syntax"/>
        </valueField>
       </optional>
       <optional>
        <valueField name="three">
         <typeFromField fieldName="Syntax"/>
        </valueField>
        <default literalValue="0"/>
       </optional>
      </class>

9.2.5.  VariableTypeValueSetFieldSpec Translation

   The attribute form translation of an object class reference a VariableTypeValueSetFieldSpec where the
   ValueSetOptionalitySpec is absent is an
   attribute element item with the
   [local name] "class". "valueSetField".

   The [normalized value]
   of this attribute item is the qualified name referencing the object
   class definition (see Section 5.1).  In the case translation of a
   UsefulObjectClassReference, the namespace name is
   "urn:ietf:params:xml:ns:asnx" and the local part is either
   "TYPE-IDENTIFIER" or "ABSTRACT-SYNTAX", as appropriate.  The
   attribute form translation SHALL NOT be used if the qualified name is
   shared by two or more object class definitions in separate modules,
   i.e., is ambiguous.  Otherwise, the translator is free to choose
   either VariableTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of the attribute form or element form translation for an object
   class reference.

   The element "OPTIONAL" form translation of an object class reference is an element item
   with the [local name] "class". "optional".  An attribute element item with the
   [local name] "ref" "valueSetField" SHALL be added to the [attributes] [children] of the
   <class>
   <optional> element item.

   The [normalized value] of this attribute item
   is the qualified name referencing the object class definition.  In
   the case translation of a UsefulObjectClassReference the namespace name is
   "urn:ietf:params:xml:ns:asnx" and VariableTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of the local part "DEFAULT ValueSet" form is either
   "TYPE-IDENTIFIER" or "ABSTRACT-SYNTAX", as the case may be.  If an element
   item with the
   reference name is not distinct [local name] "optional".  An element item with respect the
   [local name] "valueSetField" SHALL be added to the current module and [children] of the modules referenced by its <import>
   <optional> element item.  An element items (see
   Section 5.1), then an attribute item with the [local name] "context"
   "default" SHALL be added appended to the [attributes] [children] of the <class> <optional>
   element item,
   otherwise if item.  The translation of the module containing ValueSet in the referenced object class
   definition has a schema identity URI, then an
   ValueSetOptionalitySpec SHALL be added to the [children] of the
   <default> element item.

   An attribute item with the [local name] "context" MAY "name" SHALL be added to the



Legg                      Expires 22 June 2007                 [Page 71]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   [attributes] of the
   <class> <valueSetField> element item.  The
   [normalized value] of this attribute item is the schema identity URI of the module containing the referenced
   object class definition.

      Aside: If a reference name is not distinct, then
   valuesetfieldreference in the module
      containing VariableTypeValueSetFieldSpec, without
   the referenced definition must have a schema identity
      URI (see Section 5.1). ampersand character ('&', U+0026).  An element item with the
   [local name] "annotation" MAY be added to the [children] of the <class>
   <valueSetField> element item.

   The translation of the DefinedObjectClass is  An element item with the same whether [local name]
   "typeFromField" SHALL be appended to the
   object class definition is referenced by an objectclassreference or
   an ExternalObjectClassReference.

   If a DefinedObjectClass is a DummyReference, then [children] of the
   <valueSetField> element item.  The translation of the DefinedObjectClass is FieldName in
   the translation VariableTypeValueSetFieldSpec SHALL be added to the [children] or
   [attributes] of the DummyReference (see
   Section 5.9).

9.2.  ObjectClassDefn Translation <typeFromField> element item.

   Example

      CLASS {
          &Syntax DEFAULT INTEGER,
          &One    &Syntax,
          &Two    &Syntax OPTIONAL,
          &Three  &Syntax DEFAULT { 1 | 2 }
      }

      <class>
       <optional>
        <typeField name="Syntax"/>
        <default type="asnx:INTEGER"/>
       </optional>
       <valueSetField name="One">
        <typeFromField fieldName="Syntax"/>
       </valueSetField>
       <optional>
        <valueSetField name="Two">
         <typeFromField fieldName="Syntax"/>
        </valueSetField>
       </optional>
       <optional>
        <valueSetField name="Three">
         <typeFromField fieldName="Syntax"/>
        </valueSetField>
        <default>
         <valueSet>
          <union>
           <literalValue>1</literalValue>
           <literalValue>2</literalValue>
          </union>
         </valueSet>
        </default>
       </optional>
      </class>




Legg                      Expires 20 April 22 June 2007                 [Page 74] 72]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


9.2.6.  FieldName Translation

   The translation of an ObjectClassDefn a FieldName is either, at the translator's option,
   an element attribute item with the [local name] "class".  An "fieldName" added to the
   [attributes] of the enclosing element item, or an element item with
   the [local name]
   "annotation" MAY be added "fieldName" appended to the [children] of the <class>
   enclosing element item.

   The translation [normalized value] of each FieldSpec the fieldName attribute item is a solidus
   ('/', U+002F) separated list of the PrimitiveFieldName instances in
   the ObjectClassDefn SHALL FieldName, without the ampersand characters ('&', U+0026).
   Leading and/or trailing white space characters MAY be appended added to the [children]
   [normalized value] of the <class> element attribute item.  White space characters MAY
   be added immediately before and/or after any solidus character ('/',
   U+002F) in the [normalized value].

   The translation [children] property of a FieldSpec the <fieldName> element item is set to the translation
   sequence of either a
   TypeFieldSpec, a FixedTypeValueFieldSpec, a
   VariableTypeValueFieldSpec, a FixedTypeValueSetFieldSpec, character items for a
   VariableTypeValueSetFieldSpec, an solidus ('/', U+002F) separated
   list of the PrimitiveFieldName instances in the FieldName, without
   the ampersand characters ('&', U+0026).  Leading and/or trailing
   white space character items MAY be added to the [children] of the
   <fieldName> element item.  White space character items MAY be added
   immediately before and/or after any character item for the solidus
   character ('/', U+002F).

   Example

      &Linked.&ArgumentType

      <fieldName>Linked/ArgumentType</fieldName>

9.2.7.  ObjectFieldSpec or an
   ObjectSetFieldSpec.

9.2.1.  TypeFieldSpec Translation

   The translation of a TypeFieldSpec an ObjectFieldSpec where the TypeOptionalitySpec ObjectOptionalitySpec
   is absent is an element item with the [local name] "typeField". "objectField".

   The translation of a TypeFieldSpec ObjectFieldSpec with a TypeOptionalitySpec ObjectOptionalitySpec of
   the "OPTIONAL" form is an element item with the [local name]
   "optional".  An element item with the [local name] "typeField" "objectField"
   SHALL be added to the [children] of the <optional> element item.

   The translation of a TypeFieldSpec ObjectFieldSpec with a TypeOptionalitySpec ObjectOptionalitySpec of
   "DEFAULT"
   the "DEFAULT Object" form is an element item with the [local name]
   "optional".  An element item with the [local name] "typeField" "objectField"
   SHALL be added to the [children] of the <optional> element item.  An
   element item with the [local name] "default" SHALL be appended to the
   [children] of the <optional> element item.  The translation of the Type
   Object in the
   TypeOptionalitySpec ObjectOptionalitySpec SHALL be added to the [children]



Legg                      Expires 22 June 2007                 [Page 73]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   or [attributes] of the <default> element item.

   An attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the <typeField> <objectField> element item.  The
   [normalized value] of this attribute item is the typefieldreference of objectfieldreference
   in the
   TypeFieldSpec, ObjectFieldSpec, without the ampersand ("&", character ('&',
   U+0026).  An element item with the [local name] "annotation" MAY be
   added to the [children] of the <typeField> <objectField> element item.  The
   translation of the DefinedObjectClass in the ObjectFieldSpec SHALL be
   added to the [children] or [attributes] of the <objectField> element
   item.

   Example

      CLASS {
          &One,
          &Two    OPTIONAL,
          &Three  DEFAULT OBJECT IDENTIFIER
      }

      <class>
       <typeField name="One"/>



Legg                      Expires 20 April 2007                [Page 75]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006
          &one    TYPE-IDENTIFIER,
          &two    ABSTRACT-SYNTAX OPTIONAL,
          &three  TYPE-IDENTIFIER DEFAULT myObject
      }

      <class>
       <objectField name="one" class="asnx:TYPE-IDENTIFIER"/>
       <optional>
        <typeField name="Two"/>
        <objectField name="two" class="asnx:ABSTRACT-SYNTAX"/>
       </optional>
       <optional>
        <typeField name="Three"/>
        <objectField name="three" class="asnx:TYPE-IDENTIFIER"/>
        <default type="asnx:OBJECT-IDENTIFIER"/> object="tns:myObject"/>
       </optional>
      </class>

9.2.2.  FixedTypeValueFieldSpec

9.2.8.  ObjectSetFieldSpec Translation

   The translation of a FixedTypeValueFieldSpec an ObjectSetFieldSpec where the
   ValueOptionalitySpec
   ObjectSetOptionalitySpec is absent is an element item with the
   [local name] "valueField". "objectSetField".

   The translation of a FixedTypeValueFieldSpec ObjectSetFieldSpec with a
   ValueOptionalitySpec an
   ObjectSetOptionalitySpec of the "OPTIONAL" form is an element item
   with the [local name] "optional".  An element item with the
   [local name]
   "valueField" "objectSetField" SHALL be added to the [children] of the
   <optional> element item.

   The translation of a FixedTypeValueFieldSpec ObjectSetFieldSpec with a
   ValueOptionalitySpec an
   ObjectSetOptionalitySpec of "DEFAULT" the "DEFAULT ObjectSet" form is an
   element item with the [local name] "optional".  An element item with
   the [local name]
   "valueField" "objectSetField" SHALL be added to the [children] of
   the <optional> element item.  An element item with the [local name]



Legg                      Expires 22 June 2007                 [Page 74]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   "default" SHALL be appended to the [children] of the <optional>
   element item.  The translation of the Value ObjectSet in the ValueOptionalitySpec
   ObjectSetOptionalitySpec SHALL be added to the [children] or
   [attributes] of the <default> element item.

   An attribute item with the [local name] "name" SHALL be added to the
   [attributes] of the <valueField> <objectSetField> element item.  The
   [normalized value] of this attribute item is the valuefieldreference
   of
   objectsetfieldreference in the FixedTypeValueFieldSpec, ObjectSetFieldSpec, without the
   ampersand ("&", character ('&', U+0026).
   If the "UNIQUE" keyword is present, then an attribute item with the
   [local name] "unique" and [normalized value] "true" or "1" SHALL be
   added to the [attributes] of the <valueField> element item, otherwise
   an attribute item with the [local name] "unique" and
   [normalized value] "false" or "0" MAY be added to the [attributes] of
   the <valueField> element item.  An element item with the
   [local name] "annotation" MAY be added to the [children] of the <valueField>
   <objectSetField> element item.  The translation of the Type
   DefinedObjectClass in the
   FixedTypeValueFieldSpec ObjectSetFieldSpec SHALL be added to the
   [children] or [attributes] of the <valueField> <objectSetField> element item.

   Example

      CLASS {



Legg                      Expires 20 April 2007                [Page 76]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


          &one    OBJECT IDENTIFIER UNIQUE,
          &two    BOOLEAN
          &One    TYPE-IDENTIFIER,
          &Two    ABSTRACT-SYNTAX OPTIONAL,
          &three  INTEGER
          &Three  TYPE-IDENTIFIER DEFAULT 0 { myObject }
      }

      <class>
       <valueField name="one" unique="true"
                   type="asnx:OBJECT-IDENTIFIER"/>
       <objectSetField name="One" class="asnx:TYPE-IDENTIFIER"/>
       <optional>
        <valueField name="two" type="asnx:BOOLEAN"/>
        <objectSetField name="Two" class="asnx:ABSTRACT-SYNTAX"/>
       </optional>
       <optional>
        <valueField name="three" type="asnx:INTEGER"/>
        <default literalValue="0"/>
        <objectSetField name="Three" class="asnx:TYPE-IDENTIFIER"/>
        <default>
         <objectSet>
          <object ref="tns:myObject"/>
         </objectSet>
        </default>
       </optional>
      </class>

9.2.3.  FixedTypeValueSetFieldSpec

10.  Translation of Objects

   The translation of a FixedTypeValueSetFieldSpec where the
   ValueSetOptionalitySpec is absent is an element item with Object is the
   [local name] "valueSetField". translation of the DefinedObject,
   ObjectDefn, ObjectFromObject or ParameterizedObject in the Object.

   The translation of a FixedTypeValueSetFieldSpec with ParameterizedObject is described in Section 13.

10.1.  DefinedObject Translation

   If a
   ValueSetOptionalitySpec DefinedObject is an objectreference (not a DummyReference) or an



Legg                      Expires 22 June 2007                 [Page 75]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   ExternalObjectReference, then the translation of "OPTIONAL" the DefinedObject is
   either the attribute form translation of an object reference, or the
   element form translation of an object reference.

   The attribute form translation of an object reference is an attribute
   item with the [local name] "optional".  An element "object".  The [normalized value] of this
   attribute item with is a qualified name for the [local name]
   "valueSetField" expanded name of the
   referenced object definition (see Section 5.1).  The attribute form
   translation SHALL NOT be added used if this expanded name is not distinct
   with respect to the [children] of current module and the <optional> modules referenced by its
   <import> element item. items (see Section 5.1).

   The element form translation of a FixedTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of "DEFAULT" an object reference is an element
   item with the [local name] "optional". "object".  An element item with the
   [local name]
   "valueSetField" SHALL "annotation" MAY be added to the [children] of the <optional>
   <object> element item.  An element attribute item with the [local name] "default" "ref"
   SHALL be appended added to the [children] [attributes] of the <optional> <object> element item.  The
   translation
   [normalized value] of this attribute item is a qualified name for the ValueSet in
   expanded name of the ValueSetOptionalitySpec referenced object definition.  If this expanded
   name is not distinct with respect to the current module and the
   modules referenced by its <import> element items, then an attribute
   item with the [local name] "context" SHALL be added to the [children]
   [attributes] of the <default> <object> element item.

   An item, otherwise if the module
   containing the referenced object definition has a schema identity
   URI, then an attribute item with the [local name] "name" SHALL "context" MAY be
   added to the [attributes] of the <valueSetField> <object> element item.  The
   [normalized value] of this attribute item is the
   valuesetfieldreference of schema identity URI
   of the module containing the referenced object definition.

      Aside: If a reference name is not distinct, then the module
      containing the referenced definition must have a schema identity
      URI (see Section 5.1).

   The translation of the DefinedObject is the same whether the FixedTypeValueSetFieldSpec, without object
   definition is referenced by an objectreference or an
   ExternalObjectReference.

   Usually the
   ampersand ("&", U+0026).  An translator is free to choose either the attribute form or
   element item with form translation for an object reference, however in some
   contexts the [local name]
   "annotation" MAY be added to attribute form is explicitly disallowed.

   If a DefinedObject is a DummyReference, then the [children] translation of the <valueSetField>
   element item.  The
   DefinedObject is the translation of the Type in the
   FixedTypeValueSetFieldSpec SHALL be added DummyReference (see
   Section 13).

10.2.  ObjectDefn Translation

   An ObjectDefn that is a DefinedSyntax is first converted to the [children] or
   [attributes] of the <valueSetField> element item.



Legg                      Expires 20 April 22 June 2007                 [Page 77] 76]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   Example

      CLASS {
          &One    UTF8String,
          &Two    BOOLEAN OPTIONAL,
          &Three  INTEGER DEFAULT { 1 | 2 }
      }

      <class>
       <valueSetField name="One" type="asnx:UTF8String"/>
       <optional>
        <valueSetField name="Two" type="asnx:BOOLEAN"/>
       </optional>
       <optional>
        <valueSetField name="Three" type="asnx:INTEGER"/>
        <default>
         <valueSet>
          <union>
           <literalValue>1</literalValue>
           <literalValue>2</literalValue>
          </union>
         </valueSet>
        </default>
       </optional>
      </class>

9.2.4.  VariableTypeValueFieldSpec Translation


   equivalent DefaultSyntax and then translated.

   The translation of a VariableTypeValueFieldSpec where the
   ValueOptionalitySpec is absent is an element item with the
   [local name] "valueField".

   The translation of a VariableTypeValueFieldSpec with a
   ValueOptionalitySpec of "OPTIONAL" ObjectDefn is an element item with the
   [local name] "optional". "object".  An element item with the [local name]
   "valueField" SHALL
   "annotation" MAY be added to the [children] of the <optional> <object> element
   item.  The translation of a VariableTypeValueFieldSpec with a
   ValueOptionalitySpec of "DEFAULT" is an element item with each FieldSetting in the
   [local name] "optional".  An element item with DefaultSyntax in
   the [local name]
   "valueField" ObjectClassDefn SHALL be added appended to the [children] of the <optional>
   <object> element item.  An

   The translation of a FieldSetting is an element item with the
   [local name] "default" SHALL
   be appended to the [children] of the <optional> element item.  The
   translation of the Value in the ValueOptionalitySpec SHALL be added
   to the [children] or [attributes] of the <default> element item. "field".  An attribute item with the [local name] "name"
   SHALL be added to the



Legg                      Expires 20 April 2007                [Page 78]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006 [attributes] of the <valueField> <field> element item.  The
   [normalized value] of this attribute item is the valuefieldreference
   of PrimitiveFieldName
   in the VariableTypeValueFieldSpec, FieldSetting, without the ampersand ("&", character ('&', U+0026).  An element item with the [local name] "annotation" MAY be
   added to the [children] of the <valueField> element item.  An element
   item with the [local name] "typeFromField" SHALL be appended to the
   [children] of the <valueField> element item.
   The translation of the
   FieldName Type, Value, ValueSet, Object or ObjectSet in
   the VariableTypeValueFieldSpec Setting in the FieldSetting SHALL be added to the [children] or
   [attributes] of the <typeFromField> <field> element item.

   Example

      -- This is the governing object class.
      ONE-OF-EVERYTHING ::= CLASS {
          &Syntax DEFAULT INTEGER,
          &one    &Syntax,
          &One,
          &two    &Syntax OPTIONAL,
          &three  &Syntax DEFAULT 0    INTEGER,
          &Three  INTEGER,
          &four   TYPE-IDENTIFIER,
          &Five   TYPE-IDENTIFIER
      }

      <namedClass name="ONE-OF-EVERYTHING">
       <class>
       <optional>
        <typeField name="Syntax"/>
        <default type="asnx:INTEGER"/>
       </optional>
       <valueField name="one">
        <typeFromField fieldName="Syntax"/>
       </valueField>
       <optional>
        <valueField name="two">
         <typeFromField fieldName="Syntax"/>
        </valueField>
       </optional>
       <optional> name="One"/>
        <valueField name="three">
         <typeFromField fieldName="Syntax"/>
        </valueField>
        <default literalValue="0"/>
       </optional> name="two" type="asnx:INTEGER"/>
        <valueSetField name="Three" type="asnx:INTEGER"/>
        <objectField name="four" class="asnx:TYPE-IDENTIFIER"/>
        <objectSetField name="Five" class="asnx:TYPE-IDENTIFIER"/>
       </class>

9.2.5.  VariableTypeValueSetFieldSpec Translation

   The translation of a VariableTypeValueSetFieldSpec where the
   ValueSetOptionalitySpec is absent is an element item with the
   [local name] "valueSetField".

   The translation of a VariableTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of "OPTIONAL" is an element item with the
      </namedClass>

      mixedBag ONE-OF-EVERYTHING ::= {
          &One    BOOLEAN,
          &two    99,
          &Three  { 1 | 2 },
          &four   myObject,
          &Five   { myObject }
      }

      <namedObject name="mixedBag" class="tns:ONE-OF-EVERYTHING">



Legg                      Expires 20 April 22 June 2007                 [Page 79] 77]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   [local name] "optional".  An element item with the [local name]
   "valueSetField" SHALL be added to the [children] of the <optional>
   element item.


       <object>
        <field name="One" type="asnx:BOOLEAN"/>
        <field name="two" literalValue="99"/>
        <field name="Three">
         <valueSet>
          <union>
           <literalValue>1</literalValue>
           <literalValue>2</literalValue>
          </union>
         </valueSet>
        </field>
        <field name="four" object="tns:myObject"/>
        <field name="Five">
         <objectSet>
          <object ref="tns:myObject"/>
         </objectSet>
        </field>
       </object>
      </namedObject>

10.3.  ObjectFromObject Translation

   The translation of a VariableTypeValueSetFieldSpec with a
   ValueSetOptionalitySpec of "DEFAULT" an ObjectFromObject is an element item with the
   [local name] "optional". "object".  An element item with the [local name]
   "valueSetField" SHALL
   "annotation" MAY be added to the [children] of the <optional> <object> element
   item.  An element item with the [local name] "default" "fromObjects" SHALL be
   appended to the [children] of the <optional> <object> element item.

   The translation of the ValueSet ReferencedObjects instance in the ValueSetOptionalitySpec
   ObjectFromObject SHALL be added to the [children] or [attributes] of
   the <default> <fromObjects> element item.

   An attribute item with

   The translation of the [local name] "name" FieldName in the ObjectFromObject SHALL be
   added to the [children] or [attributes] of the <valueSetField> <fromObjects> element
   item.  The
   [normalized value]

11.  Translation of this attribute item is Object Sets

   If an ObjectSet matches the
   valuesetfieldreference form "{ DefinedObjectSet }" (i.e., a
   DefinedObjectSet in an ObjectSetElements instance in an Elements
   instance in a lone IntersectionElements instance in a lone
   Intersections instance in a Unions instance in an ElementSetSpec in a
   RootElementSetSpec in an ObjectSetSpec without an
   AdditionalElementSetSpec), then the translator MAY use the
   translation of the VariableTypeValueSetFieldSpec, without DefinedObjectSet as the ampersand ("&", U+0026). translation of the
   ObjectSet, otherwise the translation of an ObjectSet is an element
   item with the [local name] "objectSet".  An element item with the
   [local name] "annotation" MAY be added to the [children] of the <valueSetField>



Legg                      Expires 22 June 2007                 [Page 78]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


   <objectSet> element item.  The translation of the ObjectSetSpec in
   the ObjectSet SHALL be appended to the [children] of the <objectSet>
   element item.

      Aside: An ObjectSet that is directly a DefinedObjectSet is a
      notational capability that does not exist in ASN.1, but is allowed
      in ASN.X to avoid excessive nesting of <objectSet> element items
      in the expansion of parameterized definitions.

   If an ObjectSetSpec contains only a RootElementSetSpec, then the
   translation of the ObjectSetSpec is the translation of the
   ElementSetSpec in the RootElementSetSpec.

   If an ObjectSetSpec contains a RootElementSetSpec and an ellipsis
   ("..."), then the translation of the ObjectSetSpec is the translation
   of the ElementSetSpec in the RootElementSetSpec followed by an
   element item with the [local name] "typeFromField" "extension".  If an
   AdditionalElementSetSpec is present, then the translation of the
   ElementSetSpec in the AdditionalElementSetSpec SHALL be appended added to the
   [children] of the <valueSetField> <extension> element item.  The

   If an ObjectSetSpec does not contain a RootElementSetSpec, then the
   translation of the FieldName ObjectSetSpec is an element item with the
   [local name] "extension".  If an AdditionalElementSetSpec is present,
   then the translation of the ElementSetSpec in the
   VariableTypeValueSetFieldSpec
   AdditionalElementSetSpec SHALL be added to the [children] or
   [attributes] of the <typeFromField>
   <extension> element item.

   Example

      CLASS {
          &Syntax DEFAULT INTEGER,
          &One    &Syntax,
          &Two    &Syntax OPTIONAL,
          &Three  &Syntax DEFAULT { 1 | 2 }
      }

      <class>
       <optional>
        <typeField name="Syntax"/>
        <default type="asnx:INTEGER"/>
       </optional>
       <valueSetField name="One">
        <typeFromField fieldName="Syntax"/>
       </valueSetField>
       <optional>
        <valueSetField name="Two">
         <typeFromField fieldName="Syntax"/>
        </valueSetField>
       </optional>
       <optional>

   Nested within the ElementSetSpec will be one or more
   ObjectSetElements instances.

11.1.  DefinedObjectSet Translation

   If a DefinedObjectSet is an objectsetreference (not a DummyReference)
   or an ExternalObjectSetReference, then the translation of the
   DefinedObjectSet is either the attribute form translation of an
   object set reference, or the element form translation of an object
   set reference.

   The attribute form translation of an object set reference is an
   attribute item with the [local name] "objectSet".  The
   [normalized value] of this attribute item is a qualified name for the
   expanded name of the referenced object set definition (see
   Section 5.1).  The attribute form translation SHALL NOT be used if
   this expanded name is not distinct with respect to the current module
   and the modules referenced by its <import> element items (see
   Section 5.1).




Legg                      Expires 20 April 22 June 2007                 [Page 80] 79]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


        <valueSetField name="Three">
         <typeFromField fieldName="Syntax"/>
        </valueSetField>
        <default>
         <valueSet>
          <union>
           <literalValue>1</literalValue>
           <literalValue>2</literalValue>
          </union>
         </valueSet>
        </default>
       </optional>
      </class>

9.2.6.  FieldName Translation


   The element form translation of a FieldName an object set reference is either, at the translator's option, an attribute element
   item with the [local name] "fieldName" "objectSet".  An element item with the
   [local name] "annotation" MAY be added to the
   [attributes] [children] of the enclosing element item, or an
   <objectSet> element item.  An attribute item with the [local name] "fieldName" appended
   "ref" SHALL be added to the [children] [attributes] of the
   enclosing <objectSet> element
   item.  The [normalized value] of the fieldName this attribute item is a "/"
   (U+002F) separated list qualified
   name for the expanded name of the primitive field names without referenced object set definition.
   If this expanded name is not distinct with respect to the
   ampersand characters ("&", U+0026).  Leading and/or trailing white
   space characters MAY current
   module and the modules referenced by its <import> element items, then
   an attribute item with the [local name] "context" SHALL be added to
   the [normalized value] [attributes] of the <objectSet> element item, otherwise if the
   module containing the referenced object set definition has a schema
   identity URI, then an attribute item.  White space characters item with the [local name] "context"
   MAY be added immediately
   before and/or after any "/" character in to the [normalized value].

   The [children] property [attributes] of the <fieldName> <objectSet> element item.
   The [normalized value] of this attribute item is set to the
   sequence schema identity
   URI of character items for the module containing the referenced object set definition.

      Aside: If a "/" (U+002F) separated list reference name is not distinct, then the module
      containing the referenced definition must have a schema identity
      URI (see Section 5.1).

   The translation of the
   primitive field names without DefinedObjectSet is the ampersand characters ("&", U+0026).
   Leading and/or trailing white space character items MAY be added to same whether the [children] of
   object definition is referenced by an objectsetreference or an
   ExternalObjectSetReference.

   Usually the <fieldName> translator is free to choose either the attribute form or
   element item.  White space
   character items MAY be added immediately before and/or after any
   character item form translation for an object set reference, however in some
   contexts the "/" character.

   Example

      &Linked.&ArgumentType

      <fieldName>Linked/ArgumentType</fieldName>

9.2.7.  ObjectFieldSpec attribute form is explicitly disallowed.

   If a DefinedObjectSet is a DummyReference, then the translation of
   the DefinedObjectSet is the translation of the DummyReference (see
   Section 13).

11.2.  ObjectSetElements Translation

   The

   If an ObjectSetElements instance is an Object, then the translation
   of the ObjectSetElements instance is the translation of the Object,
   except that the attribute form of the DefinedObject translation SHALL
   NOT be used if the Object is a DefinedObject.

   If an ObjectFieldSpec where ObjectSetElements instance is a DefinedObjectSet, then the ObjectOptionalitySpec
   translation of the ObjectSetElements instance is absent the translation of
   the DefinedObjectSet, except that the attribute form of the
   DefinedObjectSet translation SHALL NOT be used.

   If an ObjectSetElements instance is an element item with ObjectSetFromObjects, then the [local name] "objectField".
   translation of the ObjectSetElements instance is the translation of
   the ObjectSetFromObjects.



Legg                      Expires 20 April 22 June 2007                 [Page 81] 80]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   The translation of a ObjectFieldSpec with a ObjectOptionalitySpec of
   "OPTIONAL" is


   If an element item with ObjectSetElements instance is a ParameterizedObjectSet, then
   the [local name] "optional".  An
   element item with translation of the [local name] "objectField" SHALL be added to ObjectSetElements instance is the [children] translation
   of the <optional> element item. ParameterizedObjectSet (see Section 13).

      Aside: The translation in-line expansion of a ObjectFieldSpec with ParameterizedObjectSet results
      in an ObjectSet.  An ObjectSetElements instance that is an
      ObjectSet is a ObjectOptionalitySpec notational capability that does not exist in ASN.1,
      but is allowed in ASN.X to avoid the need to manufacture a
      reference name for the expanded parameterized definition.

11.2.1.  ObjectSetFromObjects Translation

   The translation of
   "DEFAULT" an ObjectSetFromObjects instance is an element
   item with the [local name] "optional". "objectSet".  An element item with the
   [local name] "objectField" SHALL name] "annotation" MAY be added to the [children] of the <optional>
   <objectSet> element item.  An element item with the [local name] "default"
   "fromObjects" SHALL be appended to the [children] of the
   <optional> <objectSet>
   element item.

   The translation of the Object ReferencedObjects instance in the
   ObjectOptionalitySpec
   ObjectSetFromObjects SHALL be added to the [children] or [attributes]
   of the <default> <fromObjects> element item.

   An attribute item with

   The translation of the [local name] "name" FieldName in the ObjectSetFromObjects SHALL be
   added to the [children] or [attributes] of the <objectField> <fromObjects> element
   item.  The
   [normalized value]

12.  Translation of this attribute item Information From Objects

   If a ReferencedObjects instance is a DefinedObject (not a
   DummyReference), then the objectfieldreference translation of the ObjectFieldSpec, without ReferencedObjects
   instance is the ampersand ("&", U+0026).  An
   element item with translation of the [local name] "annotation" MAY be added to DefinedObject.

   If a ReferencedObjects instance is a DefinedObjectSet (not a
   DummyReference), then the
   [children] translation of the <objectField> element item.  The ReferencedObjects
   instance is the translation of the
   DefinedObjectClass DefinedObjectSet.

   If a ReferencedObjects instance is a DummyReference,
   ParameterizedObject or ParameterizedObjectSet, then the translation
   of the ReferencedObjects instance is the translation of that
   DummyReference, ParameterizedObject or ParameterizedObjectSet (see
   Section 13).

      Aside: The in-line expansion of a ParameterizedObject or
      ParameterizedObjectSet results in an Object or ObjectSet,
      respectively.  A ReferencedObjects instance that is an Object or
      ObjectSet is a notational capability that does not exist in ASN.1,
      but is allowed in ASN.X to avoid the ObjectFieldSpec SHALL be added need to manufacture a



Legg                      Expires 22 June 2007                 [Page 81]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


      reference name for an expanded parameterized definition.

13.  Translation of Parameterized Definitions

   The translation of an ASN.1 specification into ASN.X replaces any
   DummyReference [X.683] or reference to a parameterized definition
   [X.683] with the
   [children] definition expanded in-line (except for a special
   case involving recursive parameterized types).  For example, a
   ParameterizedObject is replaced by the Object on the right hand side
   of the referenced ParameterizedObjectAssignment.

   The definition that substitutes for a DummyReference or [attributes] parameterized
   reference (e.g., the Object that substitutes for a
   ParameterizedObject) potentially comes from a different module from
   the reference.  Expanding a DummyReference or parameterized reference
   in-line puts the substitute definition into the context of the <objectField> element item.

   Example

      CLASS {
          &one    TYPE-IDENTIFIER,
          &two    ABSTRACT-SYNTAX OPTIONAL,
          &three  TYPE-IDENTIFIER DEFAULT myObject
      }

      <class>
       <objectField name="one" class="asnx:TYPE-IDENTIFIER"/>
       <optional>
        <objectField name="two" class="asnx:ABSTRACT-SYNTAX"/>
       </optional>
       <optional>
        <objectField name="three" class="asnx:TYPE-IDENTIFIER"/>
        <default object="tns:myObject"/>
       </optional>
      </class>

9.2.8.  ObjectSetFieldSpec Translation module
   containing the reference, which could therefore alter the
   interpretation of the substitute definition.

   A type definition is potentially dependent on the TagDefault and
   ExtensionDefault of the module in which it appears, and may also be
   affected by encoding instructions in an XML Encoding Rules (XER)
   [X.693] encoding control section [X.693-1].  Other kinds of
   definitions are not dependent on the module context, however type
   definitions can be nested within the other kinds of definitions, so a
   change of context can still be significant.

      Aside: Type definitions are not dependent on their module's RXER
      or Generic String Encoding Rules (GSER) [GSER] encoding control
      section [RXEREI][GSEREI] (as they are currently defined), so the
      presence of an encoding control section for RXER or GSER is not
      significant in a change of context.

   The remainder of this section describes how and when a change of
   context is indicated in the ASN.X translation of an ObjectSetFieldSpec where a DummyReference or
   parameterized reference.

   In any instance of use, the module containing the DummyReference or
   parameterized reference is the referencing module and the module
   providing the substitute definition is the referenced module.  The
   referenced and referencing modules may be the same module.

   In the case of a ParameterizedType, the
   ObjectSetOptionalitySpec substitute definition is absent the
   Type on the right hand side of the referenced
   ParameterizedTypeAssignment.

   In the case of a ParameterizedValueSetType, the substitute definition
   is an element item with the
   [local name] "objectSetField". constrained type on the right hand side of the notional



Legg                      Expires 20 April 22 June 2007                 [Page 82]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20,      December 22, 2006


   The translation


   ParameterizedTypeAssignment equivalent to the referenced
   ParameterizedValueSetTypeAssignment (see Clause 15.8 of a ObjectSetFieldSpec with a
   ObjectSetOptionalitySpec X.680
   [X.680]).

   In the case of "OPTIONAL" is an element item with a ParameterizedValue, the
   [local name] "optional".  An element item with substitute definition is the [local name]
   "objectSetField" SHALL be added to
   Value on the [children] right hand side of the <optional>
   element item.

   The translation referenced
   ParameterizedValueAssignment.

   In the case of a ObjectSetFieldSpec with a
   ObjectSetOptionalitySpec of "DEFAULT" ParameterizedObjectClass, the substitute definition
   is an element item with the
   [local name] "optional".  An element item with ObjectClass on the [local name]
   "objectSetField" SHALL be added to right hand side of the [children] referenced
   ParameterizedObjectClassAssignment.

   In the case of a ParameterizedObject, the <optional>
   element item.  An element item with substitute definition is
   the [local name] "default" SHALL
   be appended to Object on the [children] right hand side of the <optional> element item.  The
   translation referenced
   ParameterizedObjectAssignment.

   In the case of a ParameterizedObjectSet, the substitute definition is
   the ObjectSet in on the ObjectSetOptionalitySpec SHALL be
   added right hand side of the referenced
   ParameterizedObjectSetAssignment.

   If the ActualParameter corresponding to a DummyReference is not a
   ValueSet, then the [children] substitute definition for that DummyReference is
   the Type, Value, DefinedObjectClass, Object or [attributes] of ObjectSet in the <default> element
   item.

   An attribute item with
   ActualParameter.

   If the [local name] "name" SHALL be added ActualParameter corresponding to a DummyReference is a
   ValueSet, then the substitute definition for that DummyReference is
   the notional constrained type equivalent to the
   [attributes] ValueSet; the
   ElementSetSpecs of the <objectSetField> element item.  The
   [normalized value] ValueSet contributes to the constraint of this attribute item is the
   objectsetfieldreference
   constrained type and the governor of the ObjectSetFieldSpec, without Parameter corresponding to
   the
   ampersand ("&", U+0026).  An element item ActualParameter is used as the parent type that is constrained.

   Definition (interchangeable): The contexts of the referencing and
   referenced modules are interchangeable with respect to interpreting
   the [local name]
   "annotation" MAY substitute definition if:

   (1) the referenced module is the referencing module and does not
       contain an XER encoding control section, or

   (2) the referenced module and referencing module have the same
       TagDefault (where an absent TagDefault is taken to be added equivalent
       to "EXPLICIT TAGS"), the [children] referenced module and referencing module
       have the same ExtensionDefault, and neither module has an XER
       encoding control section.

      Aside: A module with an XER encoding control section is not
      considered to have a context interchangeable with another module,
      including itself, because the typereference by which a substitute



Legg                      Expires 22 June 2007                 [Page 83]

INTERNET-DRAFT         Abstract Syntax Notation X      December 22, 2006


      type definition is identified may appear in a TargetList in the
      XER encoding control section of the <objectSetField>
   element item.  The translation referenced module, and because
      the in-line expansion of a substitute definition may cause its
      text to come within the DefinedObjectClass scope of a TargetList in the
   ObjectSetFieldSpec SHALL be added to XER encoding
      control section of the referencing module that would not apply
      otherwise.

   Definition (recursively contained): A ParameterizedType is
   recursively contained if its translation will be nested within the [children] or [attributes]
   translation (i.e., in-line expansion) of another ParameterizedType to
   which it is equivalent.  A ParameterizedValueSetType is recursively
   contained if its translation will be nested within the <objectSetField> element item.

   Example

      CLASS {
          &One    TYPE-IDENTIFIER,
          &Two    ABSTRACT-SYNTAX OPTIONAL,
          &Three  TYPE-IDENTIFIER DEFAULT { myObject }
      }

      <class>
       <objectSetField name="One" class="asnx:TYPE-IDENTIFIER"/>
       <optional>
        <objectSetField name="Two" class="asnx:ABSTRACT-SYNTAX"/>
       </optional>
       <optional>
        <objectSetField name="Three" class="asnx:TYPE-IDENTIFIER"/>
        <default>
         <objectSet>
          <object ref="tns:myObject"/>
         </objectSet>
        </default>
       </optional>
      </class>



Legg                      Expires 20 April 2007                [Page 83]

INTERNET-DRAFT         Abstract Syntax Notation X       October 20, 2006


10.  Translation of Objects

   The translation of an Object
   another ParameterizedValueSetType to which it is equivalent.

      Aside: ASN.1 does not permit the translation other kinds of either a
   DefinedObject, an ObjectDefn, an ObjectFromObject or a
   ParameterizedObject. parameterized
      reference to be recursive.

   The translation of a ParameterizedObject DummyReference, a ParameterizedType that is described in Section 5.9.

10.1.  DefinedObject Translation

   If not
   recursively contained, a DefinedObject ParameterizedValue, a
   ParameterizedValueSetType that is an objectreference (not not recursively contained, a DummyReference)