Types

The system of types is a hierarchical system based on set inclusion.

Sub-types of a given type are also sub-types of any super-type of the given type: that is, if A is a sub-type of B and C is a super-type of B, then A is a sub-type of C.

The value of each base structure element belongs to one the types defined in this clause. The definitions identify each type as a base type, a sub-type of a base type, or a super-type of two or more other types; and identifies the set of values of the type.

Equality for values of a type is defined for each of the base types for which a definition of equality is required. Two values of a type which is a sub-type of a single base type are equal if and only if they are equal as values of the base type. Equality for values of a type which includes values of more than one base type is defined for each such type.

  • Two values of a type which is a super-type of two or more base types are always equal if they are values of the same base type and are equal as values of that base type.
  • With the exception of the Glyph Identifier type, two values of a type which is a super-type of two or more base types are equal only if they are values of the same base type and are equal as values of that base type. In the case of the of the Glyph Identifier type, two values which are of different subtypes may also be equal: see .
  • Boolean type

    The Boolean type is a base type. The set of values of the Boolean type consists of two values, true and false. Two values of the Boolean type are equal if and only if they are the same.

    Enumerated types

    There are a number of Enumerated types. Each Enumerated type is a base type. The set of values of each Enumerated type consists of a finite list of values. The meaning of the values is specified by the type definition. The representation of the values depends on the Structure Representation and Interchange Format being used. Two Enumerated type values are equal if and only if they are values of the same Enumerated type and are the same. Values of two distinct Enumerated types are always unequal.

    Integer type

    The Integer type is a base type. The set of values of the Integer type consists of the subset of the mathematical integers that are greater than or equal to the integer MinInteger and less than or equal to the integer MaxInteger. Two values of the Integer type are equal if and only if they are numerically equal.

    The values of the integers MinInteger and MaxInteger are system dependent. The minimum value for MaxInteger and the maximum value for MinInteger are specified in . The set of values of the Integer type includes all of the the integers between -231+1 and 231-1 inclusive.

    Cardinal type

    The Cardinal type is a sub-type of the Integer type. The set of values of the Cardinal type consists of the non-negative values of the Integer type.

    Positive Integer Type

    The Positive Integer type is a sub-type of the Integer type. The set of values of the Positive Integer type consists of the positive values of the Integer type (excluding zero).

    Real type

    The Real type is a base type. The set of values of the Real type is a subset of the mathematical rational numbers. Two values of the Real type are equal if and only if they are numerically equal.

    The set of rational numbers included in the set of values of the Real type is system dependent. The minimum set of rational numbers which shall be included in the set of values of the Real type is specified in . The set of values of the Real type includes all of the rational numbers which can be represented as basic single width floating point binary numbers as specified by IEEE 754:1987.

    Number type

    The Number type is a super-type of the Integer type and the Real type. The set of values of the Number type consists of the union of the set of values of the Integer type and the set of values of the Real type. Two values of the Number type are equal if and only if they are both values of the same base type and are equal as values of that base type.

  • A value of the Real type is distinct from a value of the Integer type even if the two values are numerically equivalent.
  • There are some circumstances under which values of Integer type are automatically converted to the numerically equivalent values of the Real type. For example, see 20.1.8 (Equal operator).
  • Non-Negative Number type

    The Non-Negative Number type is a sub-type of the Number type. The set of values of the Non-Negative Number type consists of the union of the set of values of the Cardinal type and the set of values of the Real type which are greater than zero. Two values of the Non-Negative Number type are equal if and only if they are both values of the same base type and are equal as values of that base type.

    Printable String type

    The Printable String type is a base type. The set of values of the Printable String type consists of the set of PrintableStrings defined in ISO/IEC 8824. There is no definition of equality for values of the Printable String type.

    Octet String type

    The Octet String type is a base type. The set of values of the Octet String type consists of all sequences of octets. There is no definition of equality for values of the Octet String type. Instances of the Content Representation and Interchange Format are represented in structure by values of the OctetString type.

    Name type

    The Name type is a sub-type of the Identifier type. The set of values of the Name type is defined in . Two values of the Name type are equal if the corresponding octet strings, as defined in , are the same.

    Object Identifier type

    The Object Identifier type is a base type. The set of values of the Object Identifier type. consists of the set of object identifier values defined by ISO/IEC 8824. Two values of the Object Identifier type are equal if and only if they consist of the same sequence of numbers.

    The content representation of an Object Identifier is an OctetStringReference which references an OctetString which contains the character string representation of the Object Identifier value encoded using ISO/IEC 646 IRV. The character string representation of the Object Identifier value consists of a sequence of numeric strings S1 . .Sn, separated by period (".") characters Each of the numeric strings consists of either the single digit "0" or one or more of the digits 0 . . 9, beginning with a digit other than "0". The first string S1 is the decimal representation of the first number of the Object Identifier value, the second string S2 is the decimal representation of the second number of the Object Identifier value, and so on, with the last string Sn representing the last number of the Object Identifier value.

    Public Identifier type

    The Public Identifier type is a base type. The set of values of the Public Identifier type consists of the set of public identifiers as defined by ISO/IEC 9070. Two values of the Public Identifier type are equal if and only if they are equal as public identifiers. ISO/IEC 9070 specifies that the canonical character string form of public identifiers be used for internal equality comparisons.

    The content representation of a public identifier is an OctetStringReference which references an OctetString which contains the canonical character string form of the public identifier, encoded using ISO/IEC 646 IRV.

    Public Object Identifier type

    The Public Object Identifier type is a super-type of the Object Identifier type and the Public Identifier type. The set of values of the Public Object Identifier type consists of the union of the set of values of the Object Identifier type and the Public Identifier type. Two values of the Public Object Identifier type are equal if and only if they are both values of the same base type and are equal as values of that base type.

    Environment Name type

    The Environment Name type is a base type. The set of values of the Environment Name type consists of the set of object-name components as defined by ISO/IEC 9070. Two values of the Environment Name type are equal if and only if they consist of the same character string.

    Environment Identifier type

    The Environment Identifier type is a super-type of the Object Identifier type, the Public Identifier type, and the Environment Name type. The set of values of the Environment Identifier type consists of the union of the set of values of these types. Two values of the Environment Identifier type are equal if and only if they are both values of the same base type and are equal as values of that type.

    Structured Glyph Name type

    The Structured Glyph Name type is a base type. The set of values of the Structured Glyph Name type is the set of structured-names as defined by ISO/IEC 9541-1. The requirement that a structured-name be "an unambiguous identifier for some object suitable for representing that object within a decentralized, distributed computer system, invariant over space and time" requires that the structured-name have both an "Owner Name" and an "Object Name", and that the "Owner Name" identify the owner unambiguously.

    Two values of the Structured Glyph Name type are equal if and only if the structured-names are equal. The public identifier which is semantically equivalent to the structured-name is defined by ISO/IEC 9070, which specifies that the canonical character string form of public identifiers be used for internal equality comparisons.

    ISO10036 Glyph Name type

    The ISO10036 Glyph Name type is a sub-type of the Structured Glyph Name type. The set of values of the ISO10036 Glyph Name type is the set of structured-names for which the Owner Name identifies the registration authority authorized by ISO/IEC 10036. Two values of the ISO10036 Glyph Name type are equal if and only if they are equal as Structured Glyph Names. The canonical character string form of the public identifier which is semantically equivalent to an ISO10036 Glyph Name is of the form "ISO/IEC 10036/RA//Glyphs::nnnn", where "nnnn" is a sequence of decimal digits beginning with a non-zero digit which represents an integer in the range of 1 to 231-1.

    Simple Glyph Name type

    The Simple Glyph Name type is a sub-type of the Name type. The set of values of the Simple Glyph Name type is the set of Names of length less than or equal to 100 characters which begin with a character other than the period (".").

    Values of the Simple Glyph Name type which are not AFII Glyph Names are semantically equivalent to public identifiers which have unregistered owner names. Specifically, the Simple Glyph Name glyphname is semantically equivalent to a public identifier for which

    Two values of the Simple Glyph Name type are equal if and only if they are equal as Names.

    AFII Glyph Name type

    The AFII Glyph Name type is a sub-type of the Simple Glyph Name type. The set of values of the AFII Glyph Name type is the set of Names for which the corresponding octet string, as defined in , is the encoding of a character string of the form "afiinnnn", where "nnnn" is a sequence of decimal digits beginning with a non-zero digit, which represents an integer in the range of 1 to 231-1.

    The AFII Glyph Name "afiinnnn" is semantically equivalent to the structured-name for which the canonical character string form of the equivalent public identifier is "ISO/IEC 10036/RA//Glyphs::nnnn" Two values of the AFII Glyph Name type are equal if and only if they are equal as Names.

    Glyph Identifier type

    The Glyph Identifier type is a super-type of the Structured Glyph Name type and the Simple Glyph Name type. The set of values of the Glyph Identifier type consists of the union of the set of values of the Structured Name type and the set of values of the Simple Glyph Name type.

    Two values of the Glyph Identifier type are equal if and only if one of the following is true: