HOME | COMPANY | SOFTWARE | DOCUMENTATION | EDUCATION & TRAINING | SALES & SERVICE

    "The Official Guide to Programming with OmniMark"

Site Map | Search:   
OmniMark Magazine Developer's Forum   

  International Edition   

OmniMark® Programmer's Guide Version 3

Detailed Table of Contents


   Disclaimer
   Credits
   Copyright

1. Introduction
   1.1 What is OmniMark?
   1.2 OmniMark's Users
   1.3 How OmniMark Works
   1.4 The High-Level Structure of OmniMark Programs
   1.5 Syntax
      1.5.1 Declaration Examples
      1.5.2 Rule Examples
      1.5.3 Function Examples
      1.5.4 Example Macro Definitions
      1.5.5 Examples of Actions
      1.5.6 Examples of Conditions
   1.6 Low-Level Syntax
      1.6.1 White Space
      1.6.2 Keywords
      1.6.3 Names
      1.6.4 Punctuation
      1.6.5 Comments
      1.6.6 Quoted Strings
      1.6.7 Numbers
   1.7 Capitalization
   1.8 Legend
      1.8.1 Prose Formatting
      1.8.2 Formatting of Syntax Descriptions

2. Types of OmniMark Programs
   2.1 OmniMark Subsystems
   2.2 Batch Translation Program Types
      2.2.1 Cross-Translation: General Document Translation
      2.2.2 Down-Translation: Translating SGML Documents
      2.2.3 Up-Translation: Translating Documents to SGML
      2.2.4 Context-Translation: Using SGML as an Intermediate Form
   2.3 Process Programs: Server-Based Translation Programs
   2.4 Program Initialization and Termination
      2.4.1 Universal Program Initialization and Termination
      2.4.2 Properties of PROCESS-START and PROCESS-END Rules
      2.4.3 The Order of Initialization and Termination Rules
   2.5 Program Input and Output
      2.5.1 Program Output Streams
      2.5.2 Program Input Sources
         2.5.2.1 Making Use of Built-In Input Sources
         2.5.2.2 Restrictions on Built-In Input Sources
      2.5.3 Controlling Input to the SGML Parser
   2.6 Accessing The Command-Line Arguments
   2.7 More Examples of OmniMark Programs
      2.7.1 Translating SGML Documents: An Example
      2.7.2 Translating Documents into SGML: An Example

3. Generalized Document Processing
   3.1 General Document Processing Rules
      3.1.1 Initializing Document Processing
      3.1.2 Terminating Document Processing
      3.1.3 Recognizing and Processing Arbitrary Input
   3.2 Programmer-Directed Input Processing
      3.2.1 Submitting Input to FIND Rules
         3.2.1.1 Submitting Files
      3.2.2 Scanning Actions
         3.2.2.1 Scanning Input With a Single Pattern
         3.2.2.2 Repeatedly Matching Input
         3.2.2.3 Side Effects in MATCH Alternatives
      3.2.3 Skipping Input
         3.2.3.1 Where Skipping Can Be Done
   3.3 Pattern Recognition
      3.3.1 Patterns Consisting of Strings
      3.3.2 Character Classes
         3.3.2.1 Predefined Character Classes
         3.3.2.2 Compound Character Classes
         3.3.2.3 Character Set Ranges
         3.3.2.4 Character Sets and Case Insensitivity
      3.3.3 Repetition and Optionality
         3.3.3.1 Numeric Occurrence Indicators
      3.3.4 Positional Patterns
         3.3.4.1 Multipe Positional Patterns at One Location
      3.3.5 Looking Ahead
      3.3.6 Parentheses in Patterns
      3.3.7 Avoiding Patterns that Loop
      3.3.8 Capturing Input Matched By Patterns
         3.3.8.1 Assigning Pattern Variables
            3.3.8.1.1 Pattern Variable Assignment Within Repeated Or Optional Patterns
         3.3.8.2 Referencing Pattern Variables
         3.3.8.3 Formatting a Pattern Variable
         3.3.8.4 Testing Whether a Pattern Variable Has Been Initialized
      3.3.9 Compound Patterns
         3.3.9.1 Factoring Out UL
      3.3.10 Conditions Inside Patterns

4. Processing SGML Documents
   4.1 Rules That Process Content
      4.1.1 Suppressing Content
      4.1.2 Processing Content
      4.1.3 An Example of "%c" Format Modifiers
   4.2 Basic SGML Rules
      4.2.1 Processing Element Content
         4.2.1.1 Default Element Processing
         4.2.1.2 Conditions On Element Rules
         4.2.1.3 Element Rule Uniqueness
         4.2.1.4 Empty Elements
      4.2.2 Processing Data Characters
         4.2.2.1 The Data Content Rule
         4.2.2.2 Translating Patterns in Data Content
         4.2.2.3 Patterns for CDATA and SDATA Entities
            4.2.2.3.1 Matching Internal Text Entities
            4.2.2.3.2 Matching Entities Based On Replacement Text
            4.2.2.3.3 Matching Entities Based On Names
            4.2.2.3.4 Matching On Both An Entity's Name And Replacement Text
            4.2.2.3.5 Combining Internal Entity and Plain-Text Matching
            4.2.2.3.6 Pattern Matching Internal Entity Names
         4.2.2.4 Writing Data Content to Multiple Streams
      4.2.3 Processing Instructions
         4.2.3.1 Processing Instruction Entities
         4.2.3.2 Record Ends in Processing Instructions
   4.3 SGML Comments and Marked Sections
      4.3.1 Processing SGML Comments
      4.3.2 IGNORE Marked Sections
      4.3.3 Processing CDATA and RCDATA Marked Sections
      4.3.4 INCLUDE Marked Sections
      4.3.5 Trapping Illegal Input
      4.3.6 Text in Comments, Marked Sections and Processing Instructions
         4.3.6.1 Dividing Up Data Content
         4.3.6.2 SGML Comments and Marked Section Boundaries
         4.3.6.3 TRANSLATE Rule Boundaries
   4.4 SGML Document Regions
      4.4.1 Processing SGML Declaration Information
      4.4.2 Processing The Document Element Name
      4.4.3 Processing At The End Of The DTD
      4.4.4 Processing Just Before The Instance
      4.4.5 Processing After The Instance
   4.5 Initializing and Terminating SGML Processing
      4.5.1 Initializing SGML Processing
      4.5.2 Terminating SGML Processing

5. Organizing Rules With Groups
   5.1 Placing Rules Into Groups
      5.1.1 The #IMPLIED Group
   5.2 Changing the Currently Active Groups
      5.2.1 Changing the Currently Active Groups Indefinitely
      5.2.2 Nesting Active Groups
      5.2.3 Adding Groups to the Currently Active Groups
      5.2.4 Saving the Active Groups
      5.2.5 Changing Groups in Functions
   5.3 Groups and Domains
   5.4 Finite State Machines

6. OmniMark Data Types
   6.1 Introduction to Variable Declarations
      6.1.1 Declaration-Free Programs
      6.1.2 Global Variable Declarations
      6.1.3 Local Variable Declarations
      6.1.4 Use of Heralds
      6.1.5 Programmer-Defined Names Containing the "#" Character
   6.2 Switches
      6.2.1 Setting the Value of a Switch Item
         6.2.1.1 Switch Activation
      6.2.2 Operations on Switches
         6.2.2.1 An Alternative Switch Value Test
   6.3 Counters
      6.3.1 Setting the Value of a Counter
      6.3.2 Incrementing and Decrementing a Counter
      6.3.3 Setting a Counter Value the Old-Fashioned Way
      6.3.4 Counter-Related Formats
         6.3.4.1 Arabic Numerals
         6.3.4.2 Alphabetic Representations of a Counter Value
         6.3.4.3 Roman Numeral Representations
         6.3.4.4 Binary Representations
   6.4 Streams
      6.4.1 Stream Domains
      6.4.2 Stream Attachments
      6.4.3 Actions On Streams
         6.4.3.1 Opening Streams
            6.4.3.1.1 Open Modifiers
            6.4.3.1.2 The Keyword FILE in Stream Attachments
         6.4.3.2 Reopening Streams
      6.4.4 Changing Modifiers on #PROCESS-OUTPUT and #ERROR
         6.4.4.1 Writing Text to a Stream
            6.4.4.1.1 Open Modifiers Allowed With PUT
            6.4.4.1.2 The Effect of PUT on the #CURRENT-OUTPUT Stream Set
         6.4.4.2 Closing a Stream
         6.4.4.3 Discarding a Stream
         6.4.4.4 Initializing Buffers
      6.4.5 Streams in String Expressions
         6.4.5.1 Formatting the Contents of a Buffer
      6.4.6 Operators on Streams
         6.4.6.1 Stream Name Test
         6.4.6.2 Getting the Name of a Referent or File
         6.4.6.3 Stream State Tests
         6.4.6.4 Stream Attachment Type Tests
         6.4.6.5 Combining Stream Tests

7. Shelves
   7.1 Shelf Declarations
      7.1.1 Declaring Global Shelves
      7.1.2 Declaring Local Shelves
      7.1.3 Shelf Sizes
      7.1.4 Initializing Shelves
   7.2 Indexing Items on a Shelf
      7.2.1 The Currently Selected Shelf Item
      7.2.2 Positional Item Selection
      7.2.3 Key-Based Item Selection
         7.2.3.1 Multi-Dimensional Arrays
      7.2.4 Lastmost Item Selection
   7.3 Actions On Shelves
      7.3.1 Adding New Items To Shelves
         7.3.1.1 Inserting a New Item With Default Initialization
         7.3.1.2 Inserting a New Item With a Specified Initialization
         7.3.1.3 Inserting Into Shelves
      7.3.2 Removing Items From a Shelf
         7.3.2.1 Removing All Items From a Shelf
         7.3.2.2 Removing a Single Item
      7.3.3 Copying Shelf Contents
         7.3.3.1 Moving Shelf Contents To Another Shelf
      7.3.4 Actions on Shelf Item Keys
         7.3.4.1 Changing or Setting the Key of a Shelf Item
         7.3.4.2 Removing the Key of a Shelf Item
   7.4 Operators on Shelves
      7.4.1 Determining the Size of a Shelf
      7.4.2 Returning the Position of an Item on a Shelf
      7.4.3 Testing a Shelf For a Given Key Value
      7.4.4 Testing a Given Item For Any Key
      7.4.5 Finding the Key of a Specific Item
   7.5 Specifying a New Default Selected Item
      7.5.1 Order of Evaluation of USING and Conditions
   7.6 Repeating Actions on Each Item of a Shelf
      7.6.1 Adding Items Inside Repeat Over Loops
      7.6.2 Loop Indices
         7.6.2.1 Testing for the First or Last Iteration of a Loop
         7.6.2.2 Retrieving The Current Iteration Count
      7.6.3 Other Forms of "REPEAT OVER"
   7.7 Saving Shelf Contents
      7.7.1 The Save Action
      7.7.2 The Save-Clear Declaration
      7.7.3 Mixing Save Actions and Local Declarations
      7.7.4 The Interaction of USING Prefixes and SAVE Declarations
         7.7.4.1 Case 1 -- Binding Shelf Instances with USING
         7.7.4.2 Case 2 -- Aliasing Errors

8. Variable Scopes
   8.1 Control Structures
      8.1.1 Compound Action Blocks
      8.1.2 Selection Structures
         8.1.2.1 Selecting Actions Based On General Conditions
         8.1.2.2 Selecting Actions Based On Numeric Values
      8.1.3 Looping
         8.1.3.1 The Basic Looping Construct
      8.1.4 Leaving a Loop
   8.2 Local Scopes
      8.2.1 Open Streams In Local Scopes
      8.2.2 Pattern Variables And Local Scopes
      8.2.3 Saving Global Variables in Local Scopes
   8.3 Halting an OmniMark Program
      8.3.1 Immediately Halting an OmniMark Program

9. Expressions And Operators
   9.1 Numeric Expressions
      9.1.1 Constant Numeric Expressions
      9.1.2 Numeric Operators
         9.1.2.1 Sign Operators
            9.1.2.1.1 The Positive Sign
            9.1.2.1.2 The Negative Sign
         9.1.2.2 Arithmetic Operators
            9.1.2.2.1 The Addition Operator
            9.1.2.2.2 The Subtraction Operator
            9.1.2.2.3 The Multiplication Operator
            9.1.2.2.4 The Division Operator
            9.1.2.2.5 The Modulus Operator
         9.1.2.3 Bit-Oriented Arithmetic
            9.1.2.3.1 The Bit-Wise Mask Operator
            9.1.2.3.2 The Bit-Wise Union Operator
            9.1.2.3.3 The Bit-Wise Difference Operator
            9.1.2.3.4 The Bit-Wise Complement Operator
            9.1.2.3.5 The Bit-Wise Shift Operator
            9.1.2.3.6 More Examples of Bit-Wise Operators
         9.1.2.4 Numeric Comparison Operators
            9.1.2.4.1 Multi-Part Numeric Comparison Tests
            9.1.2.4.2 Comparisons Which Could Be Either Numeric Or String
         9.1.2.5 Precedence of Numeric Operators
   9.2 String Expressions
      9.2.1 Quoted Strings
         9.2.1.1 Constant Format Items In Strings
            9.2.1.1.1 Ending a Line ("%n")
            9.2.1.1.2 The Space Character ("%_")
            9.2.1.1.3 The Tab Character ("%t")
            9.2.1.1.4 Entering Numeric Characters ("%#" and "%{}")
         9.2.1.2 Concatenating Quoted Strings
            9.2.1.2.1 Entering Quotation Marks
      9.2.2 Using String Expressions As Numbers
         9.2.2.1 Converting Numbers From Other Bases
         9.2.2.2 Converting Binary Data To Numbers
         9.2.2.3 The Number of Characters in a String
         9.2.2.4 Dynamic String Concatenation
         9.2.2.5 String Repetition
      9.2.3 The Precedence of the Operators BASE and BINARY
      9.2.4 Comparing String Expressions
         9.2.4.1 Combining String Expressions In A String Comparison
         9.2.4.2 Multi-Part String Comparison Tests
            9.2.4.2.1 Pattern Matching A String Expression
      9.2.5 Combining Numeric and String Operators
   9.3 Test Expressions
      9.3.1 Logical Operators
         9.3.1.1 Logical And Operator
         9.3.1.2 Logical Or Operator
         9.3.1.3 Logical Not Operator
         9.3.1.4 Conditional Evaluation of Test Expressions
         9.3.1.5 Precedence of Logical Operators
      9.3.2 Comparing Test Expressions
      9.3.3 Multi-Part Switch Comparisons
   9.4 Order of Evaluation

10. Accessing the External World
   10.1 Getting the Date and Time
      10.1.1 The Run-Time Date and Time
      10.1.2 The Compile-Time Date and Time
      10.1.3 Date Format Items
   10.2 Obtaining Information About OmniMark
      10.2.1 OmniMark Language Version
      10.2.2 OmniMark Platform Information
   10.3 Running Other Programs From OmniMark
   10.4 Manipulating Files
      10.4.1 File Tests
         10.4.1.1 Testing Whether a File Exists
         10.4.1.2 Testing Read Access to a File
         10.4.1.3 Testing Write Access to a File
         10.4.1.4 Testing If a Path Specifies a Directory
         10.4.1.5 Testing If a Path Specifies a File
         10.4.1.6 Default Handling of Input and Output Error Conditions
      10.4.2 Getting a File's Contents
         10.4.2.1 Binary And Text-Mode Files
      10.4.3 Setting File Contents

11. Cross-Referencing and Hypertext Linking
   11.1 Creating and Using Referents
      11.1.1 Local Cross-References
      11.1.2 Initializing a Referent
      11.1.3 Writing Out a Referent
      11.1.4 Writing Data to a Referent in a Piecewise Fashion
         11.1.4.1 Attaching Referents to Streams
         11.1.4.2 Other Operations on Streams Attached to Referents
   11.2 Allowing Referents to be Written to a Stream
      11.2.1 Writing Referents to Different Types of Streams
      11.2.2 The Format of Displayed Referents
      11.2.3 Copying Referents
      11.2.4 Allowing Referents in the Main Output
      11.2.5 Suppressed Referents
   11.3 Server Applications: Local Referent Sets
      11.3.1 The Current Referent Set
      11.3.2 Creating A New Referent Set
         11.3.2.1 Local Referent Sets and Domains
         11.3.2.2 The Global Referent Set
      11.3.3 Final Destinations for Referents
      11.3.4 Referent Set Nesting Depth
      11.3.5 Reopening a Referent in a Different Scope
   11.4 The Referents Shelf
      11.4.1 Getting The Current Value of a Referent
      11.4.2 Checking Whether A Referent Has Been Used
      11.4.3 Indexing The Referents Shelf
      11.4.4 The Number Of Referents
      11.4.5 Checking Whether A Referent Is Defined
      11.4.6 Iterating Over the Current Referent Set
      11.4.7 The USING Prefix and the Referents Shelf
   11.5 Default Referent Definitions
      11.5.1 Specifying Default Referent Definitions
      11.5.2 Default Referent Definitions for a Reopened Stream
      11.5.3 "Silent" Referents
   11.6 Referents and Line-Breaking

12. Functions
   12.1 The Function Definition
      12.1.1 Function Names
      12.1.2 The Function Result Type
         12.1.2.1 Value-Returning Functions
         12.1.2.2 Functions With No Result Type
      12.1.3 The Function Argument List
         12.1.3.1 Function Argument Templates
         12.1.3.2 Function Argument Classes
            12.1.3.2.1 Passing Expressions As Arguments
            12.1.3.2.2 Passing a Shelf as a Read-Only Argument
            12.1.3.2.3 Passing a Shelf as a Modifiable Argument
            12.1.3.2.4 Passing a Variable Number of Values as a Single Argument
            12.1.3.2.5 The Difference Between VALUE and READ-ONLY Arguments
         12.1.3.3 Function Argument Shelf Types
         12.1.3.4 Function Argument Separators
            12.1.3.4.1 Functions With No Arguments
            12.1.3.4.2 Argument Separators for the First Argument
         12.1.3.5 Optional Function Arguments
            12.1.3.5.1 Testing The Presence Of An Optional Argument
      12.1.4 Function Bodies
         12.1.4.1 What Can Be Done In a Function?
      12.1.5 Functions and Declaration-Free Programs
   12.2 Functions -- Shelves and Arguments
      12.2.1 The "Current Item"
      12.2.2 Modifying Read-Only Arguments
      12.2.3 Applying SAVE To Function Arguments
   12.3 External Functions
      12.3.1 Declaring an External Function
         12.3.1.1 Declaring a Default Function Library
      12.3.2 Identifying An External Function
         12.3.2.1 Enquiring About the Identity of an External Function
      12.3.3 Externally-Defined Sources
      12.3.4 External Output Functions
         12.3.4.1 Setting Output Functions
         12.3.4.2 Writing Referents to External Output Streams
   12.4 Function Calls
      12.4.1 Where Can A Function Be Called From?
      12.4.2 Argument Recognition
         12.4.2.1 Argument Recognition in the Parenthesis-and-Comma Form
         12.4.2.2 Argument Recognition in the Name-Heralded Form
         12.4.2.3 Resolving Ambiguous Argument Separators
            12.4.2.3.1 Duplicate Separators in a Function Definition
            12.4.2.3.2 Using the Same Separator in Different Functions
            12.4.2.3.3 Greedy Argument Separator Recognition
   12.5 Recursive Functions
      12.5.1 Recursion
      12.5.2 Function Predefinitions
      12.5.3 Tail Recursion
   12.6 Function Side Effects
      12.6.1 Function Side Effects In Rule Headers

13. The Current Output Stream Set
   13.1 The Output Action
   13.2 Changing the Current Output Set
   13.3 Temporarily Changing the Current Output Set
   13.4 Establishing a Current Output Set
   13.5 Changing the Current Output Stream Set in the Output Processor
      13.5.1 Changing the Current Output Stream Set in TRANSLATE Rules.

14. SGML Objects
   14.1 Elements
      14.1.1 Element Qualifiers
      14.1.2 Element Context Tests
         14.1.2.1 Testing Open Elements
            14.1.2.1.1 Testing the Identity of an Element
            14.1.2.1.2 Testing the Identity of the Parent Element
            14.1.2.1.3 Testing the Existence of a Particular Ancestor Element
            14.1.2.1.4 Testing the Existence of an Ancestor of the Parent Element
            14.1.2.1.5 Testing If a Particular Element Is Open
         14.1.2.2 Testing Recently Closed Elements
            14.1.2.2.1 Testing the Identity of the Preceding Proper Element
            14.1.2.2.2 Testing the Identity of the Last Subelement
         14.1.2.3 Data Content Tests
            14.1.2.3.1 Testing the Last Content or Subelement
         14.1.2.4 Testing the Status of Proper and Included Elements
         14.1.2.5 Counting Elements
            14.1.2.5.1 Counting Repetitions of the Current Element
            14.1.2.5.2 Counting Subelements
         14.1.2.6 Element Declaration Tests
            14.1.2.6.1 Testing the Declared Content of an Element
            14.1.2.6.2 Testing for Short Reference Maps
         14.1.2.7 Combining SGML Enquiry and Comparison
      14.1.3 Retrieving the Names of Open Elements
         14.1.3.1 Formatting Element Names
         14.1.3.2 Element Names
         14.1.3.3 The Document Element Name
      14.1.4 The Current Element Stack
         14.1.4.1 Determining Element Depth
         14.1.4.2 Iterating Over the Opened Element Context
         14.1.4.3 Element Alias Names
         14.1.4.4 Buffering Input to the SGML Parser
   14.2 Entities
      14.2.1 Formatting Entity Names
      14.2.2 Entity Tests
         14.2.2.1 INTERNAL Entities
         14.2.2.2 Entities That Are External
         14.2.2.3 External Entities With Public Identifiers
         14.2.2.4 External Entities With System Identifiers
         14.2.2.5 External Entities Defined In A Library Declaration
         14.2.2.6 CDATA Entities
         14.2.2.7 SDATA Entities
         14.2.2.8 NDATA Entities
         14.2.2.9 SUBDOC Entities
         14.2.2.10 #DEFAULT Entities
         14.2.2.11 Additional Tests in EXTERNAL-TEXT-ENTITY Rules
         14.2.2.12 Combining Entity Tests
   14.3 Notations
      14.3.1 Notation Tests
         14.3.1.1 Notations With Public Identifiers
         14.3.1.2 Notations With System Identifiers
         14.3.1.3 Notations Defined In A Library Declaration
         14.3.1.4 Combining Notation Tests
         14.3.1.5 Comparing Notation Names
   14.4 Attributes
      14.4.1 Attribute References
         14.4.1.1 Attribute Qualifiers
            14.4.1.1.1 The Using Prefix and Attribute Values
      14.4.2 List-Valued Attributes
         14.4.2.1 Counting Tokens in a List-Valued Attribute
         14.4.2.2 Iterating Over List-Valued Attributes
      14.4.3 Attribute Tests
         14.4.3.1 Testing the Source of An Attribute Value
         14.4.3.2 Attribute Type Tests
            14.4.3.2.1 Combining Attribute Type Tests
         14.4.3.3 Entity and Notation Attribute Tests
         14.4.3.4 Data Attributes Associated With Entity Attributes
            14.4.3.4.1 Using Data Attribute References
      14.4.4 Attribute Format Items
         14.4.4.1 Accessing Attribute Values
         14.4.4.2 "%v" Modifiers Specific to CDATA Attributes
         14.4.4.3 "%v" Modifiers Specific to External ENTITY or ENTITIES Attributes
         14.4.4.4 "%v" Modifiers Specific to Internal ENTITY or ENTITIES Attributes
         14.4.4.5 "%v" Modifiers Specific to NOTATION Attributes
      14.4.5 Attribute Sets
         14.4.5.1 Indexing the ATTRIBUTES Shelf
            14.4.5.1.1 Testing For Declared Attributes
            14.4.5.1.2 Getting The Name of an Attribute
            14.4.5.1.3 Getting The Position of an Attribute
            14.4.5.1.4 Getting The Number of Attributes
            14.4.5.1.5 The Order of Attributes
         14.4.5.2 Iterating Over All of the Attributes
         14.4.5.3 Selecting an Item of the ATTRIBUTES and DATA-ATTRIBUTES Shelf
            14.4.5.3.1 More About Attribute Aliases
            14.4.5.3.2 Retrieving the Key of an Attribute Alias
            14.4.5.3.3 Locking the SGML Parser Input
         14.4.5.4 Attribute Tests on Items of the ATTRIBUTES Shelf
   14.5 The #APPINFO Stream

15. Processing SGML Errors
   15.1 Catching SGML Errors
      15.1.1 Retrieving The Parts of the SGML Error Message
         15.1.1.1 Predefined Pattern Variables in the SGML-ERROR Rule
   15.2 Error Counting
   15.3 Handling Prolog Errors
      15.3.1 The Minimum Literal at the Start of the SGML Declaration

16. Processing External Entities
   16.1 SGML Entity Managers
      16.1.1 OmniMark's Built-in Entity Manager
      16.1.2 What Your Own Entity Manager Can Do
      16.1.3 Which Entity Manager Is Used?
   16.2 External Entity Rules
      16.2.1 Processing External Data and Subdocument Entities
         16.2.1.1 Attribute References In EXTERNAL-DATA-ENTITY Rules
      16.2.2 Processing External Text Entities
         16.2.2.1 Where Entities Come From and Where They Go
            16.2.2.1.1 Constructing Entity Text from Multiple Sources
            16.2.2.1.2 Combining External Entities in a Single File
         16.2.2.2 The Domains Of The External Text Entity Rule
         16.2.2.3 Using SUBMIT in the External Text Entity Rule
         16.2.2.4 OUTPUT-TO in the EXTERNAL-TEXT-ENTITY Rule
         16.2.2.5 Guarding Entity Expansion
   16.3 Accessing the Library Rules and the Library Path
      16.3.1 Manipulating the Library Rule Mappings
      16.3.2 Manipulating the Library File Search Path
      16.3.3 Manipulating Built-In Entity Replacement Text Values
      16.3.4 Restrictions on the #LIBRARY, #LIBPATH and #LIBVALUE Shelf Values
   16.4 Processing Public Identifiers
      16.4.1 The Public Identifier at the Start of the DTD
      16.4.2 Public Identifiers in the SGML Declaration
         16.4.2.1 Default Processing
         16.4.2.2 Base Character Sets
            16.4.2.2.1 Defining a Base Character Set
            16.4.2.2.2 Sources of Base Character Set Information
            16.4.2.2.3 Using Base Character Sets
         16.4.2.3 Capacity Sets
         16.4.2.4 Concrete Syntaxes
      16.4.3 Parsing Public Identifiers
   16.5 A Default External Text Entity Rule

17. SGML Document and Subdocument Parsing
   17.1 Instance and Instance Part Parsing
   17.2 The "DO SGML-PARSE" Action
      17.2.1 Specifying the Input of the SGML Parser
         17.2.1.1 Calling the Input Function of the "DO SGML-PARSE"
      17.2.2 Current Input and Output in "DO SGML-PARSE"
      17.2.3 Types of SGML Document Parsing
         17.2.3.1 SGML Document Regions
         17.2.3.2 Documents or Subdocuments?
            17.2.3.2.1 Creating DTDs
         17.2.3.3 Parsing Document Instance or Instance Parts
      17.2.4 Using "DO SGML-PARSE" Actions
   17.3 The DTDS Shelf
   17.4 Open Subdocument Depth
   17.5 SGML Parsing-Related Built-In Shelves
   17.6 An Example of Subdocument Processing

18. How Asynchronous Concurrent Context Translations Work

19. Customizing OmniMark Behaviour
   19.1 Declarations
      19.1.1 The Escape Declaration
      19.1.2 Naming Conventions
         19.1.2.1 Capitalization in General SGML Names
         19.1.2.2 Capitalization in SGML Entity Names
         19.1.2.3 Letter Characters in OmniMark Names
         19.1.2.4 Letter Characters in Data
         19.1.2.5 The LETTERS Declaration
      19.1.3 Setting Open Modifiers On Built-In Streams
         19.1.3.1 Specifying Referent Processing for #MAIN-OUTPUT
         19.1.3.2 Setting the Mode to Text or Binary for Built-In Streams
      19.1.4 Other Declarations
         19.1.4.1 Mapping Public Ids To System Ids
         19.1.4.2 Separating Attribute Tokens
         19.1.4.3 The Symbol Declaration
         19.1.4.4 The Symbol Format
         19.1.4.5 Including OmniMark Code from Other Files
         19.1.4.6 The Byte Order in the Input
         19.1.4.7 Ordering Bytes When Formatting the Binary Representation of Numbers
         19.1.4.8 Version 2 Compatibility
      19.1.5 Line Breaking
         19.1.5.1 Specifying Line Lengths
         19.1.5.2 Inserting Line Breaks
         19.1.5.3 Replacing A Sequence With A Line-Break
         19.1.5.4 The Line Break Format
         19.1.5.5 The Break Suppression Format Items
         19.1.5.6 Line Breaking, Conditions and Functions
      19.1.6 The NEWLINE Declaration and Binary I/O
   19.2 Manipulating Record Boundaries
      19.2.1 Why These Actions Are Needed
      19.2.2 Record Boundaries in the #SGML Stream
      19.2.3 Record Boundaries in the Output Processor
      19.2.4 Default Record Boundary Handling
      19.2.5 Record Ends in SGML Comments, Marked Sections and PIs

20. Macros
   20.1 Macro Syntax
      20.1.1 Invoking Macros Without Arguments
         20.1.1.1 Restrictions On Macro Use
      20.1.2 Invoking Macros With Token Arguments
      20.1.3 Delimited Macro Arguments
         20.1.3.1 Brackets In Delimited Arguments
      20.1.4 Combining Delimited and Token Arguments
      20.1.5 Inserting Macro Arguments Into Strings
         20.1.5.1 The Macro Argument Format Item
         20.1.5.2 String Arguments in Nested Macros
   20.2 How Macro Replacement Works
      20.2.1 Compound Macro Names
      20.2.2 Compound Argument Delimiters
      20.2.3 Delimiters and Macro Names
      20.2.4 Punctuation As Argument Names
      20.2.5 Protecting Macro Keywords
      20.2.6 Macros Invoked In Other Macro Declarations
      20.2.7 Macros Declared In Other Macro Declarations
   20.3 Using Macros
      20.3.1 Good Practises
      20.3.2 Application-Specific Macros
      20.3.3 A For-Loop Construct
      20.3.4 Defining Operations On A Group Of Shelves

21. Differences from OmniMark V2
   21.1 The Reduced Language
      21.1.1 Explicit Type Heralding
         21.1.1.1 Using Heralded Names To Access Hidden Variables
         21.1.1.2 Using Quoted Variable Names
         21.1.1.3 Declaration-Free Programs
      21.1.2 Impact of the Reduced Language
         21.1.2.1 Variable Names Hiding Keywords
         21.1.2.2 Backquoting Names
         21.1.2.3 The "DECLARE HERALDED-NAMES" Declaration
      21.1.3 Choosing a Solution To Incompatibility Problems
   21.2 Server Support
      21.2.1 Incompatibilities Introduced With Process Programs
   21.3 Correction of Inconsistencies
   21.4 Extended Functionality
      21.4.1 Syntactic Improvements
      21.4.2 Improved Control Over Input and Output
      21.4.3 Improved Modularity
      21.4.4 New SGML-Processing Rules
      21.4.5 New Shelf Manipulation Features
      21.4.6 Miscellaneous New Features
   21.5 Features Added in V3R0a

Copyright © OmniMark Technologies Corporation, 1988-1997. All rights reserved.
EUM27, release 2, 1997/04/11.

Home Copyright Information Website Feedback Site Map Search