Copyright © 1992, 1997 International Organization for Standardization. All rights reserved.

This electronic document is for use during development and review of International Standards. Official printed copies of International Standards can be purchased from the ISO and the national standards organization of your country.

Next ClausePrevious Clause  

homeParent clauseNext major clausePrevious major clausePrevious clause at this level


A.2 Lexical Type Definition Requirements (LTDR)

A.2.4 Lexicographic ordering definition notations

Subclauses:


Any lexicographic ordering definition notation may be used to define lexicographic orderings. The following is a non-mandatory starter set consisting of one lexicographic ordering definition notation, HyOrd, which is then defined.

      <!-- HyTime Lexicographic Ordering Definition Notation -->
<![ %HyOrd; [
<!notation
   HyOrd          -- HyTime lexicographic ordering definition
                     notation --

   PUBLIC "ISO/IEC 10744:1997//NOTATION
           HyTime Lexicographic Ordering Definition Notation
           (HyOrd)//EN"

-- CommonAttributes: altreps, included, superdcn --
>
]]><!-- HyOrd -->

A.2.4.1 HyTime lexicographic ordering definition notation (HyOrd)

The HyOrd notation provides a syntax for representing mappings from the members of lists of characters to the corresponding members of other lists of characters and from sequences of characters to other sequences of characters.

Characters lists for use in either kind of mapping are specified as SGML literals or as bracketed lists of decimal character numbers.

The syntax for HyOrd specifications is:
HyOrd specification =
HyOrd separator*,
HyOrd statement,
( HyOrd separator+,
  HyOrd statement )*,
HyOrd separator*,
HyOrd separator =
s |
comment
HyOrd statement =
correspondent character mapping |
character sequence mapping
correspondent character mapping =
character list specification,
HyOrd separator*,
pero,
HyOrd separator*,
character list specification
character sequence mapping =
character list specification,
HyOrd separator*,
vi,
HyOrd separator*,
character list specification
character list specification =
literal character list |
numeric character list
literal character list =
( lit,
  SGML character*,
  lit ) |
( lita,
  SGML character*,
  lita )
numeric character list =
dso,
s*,
( number,
  ( s+,
    number )*
  s* )?
dsc

The left-hand side of any HyOrd statement must be a list of at least one character. If several character sequences to be mapped begin with the same character sequence, only the longest sequence is mapped.

The right-hand side of a correspondent character mapping must be a list containing the same number of characters as the left-hand side of the statement, except that the right-hand side of a character sequence mapping may be an empty list of characters.

NOTE 391 The following example of a HyOrd specification illustrates one-to-none, one-to-one, one-to-many and many-to-one reorderings.

"adh" % [1 4 8]  -- a compares as 1, d compares as 4, and h compares as 8 --
"j"   = [4 27 8] -- j compares as dzh --
"l"   = [12]     -- l compares as 12 --
"ll"  = [13]     -- ll occurs between l and m --
"m"   = [14]     -- m compares as 14
"'"   = ""       -- apostrophe ignored in compare --
"z"   = [27]     -- z compares as 27 --

Next ClausePrevious Clause  

Copyright © 1992, 1997 International Organization for Standardization. All rights reserved.

This electronic document is for use during development and review of International Standards. Official printed copies of International Standards can be purchased from the ISO and the national standards organization of your country.


HTML generated from the original SGML source using a DSSSL style specification and the SGML output back-end of the JADE DSSSL engine.