contentsconceptssyntaxlibrariessampleserrorsindex
Full text search
Rules
Prerequisite Concepts      

OmniMark is a primarily event-driven programming language. This means that OmniMark programs are largely made up of different pieces of code that are executed when certain events are encountered during the processing of an input document. The actions that the program executes, and the definition of the events that cause these actions to be executed, are defined in rules.

A rule is made up of two parts -- a rule header and a rule body.

In the rule header you define the event which, when encountered in an input document, will cause a certain action or set of actions to be executed. Rule headers are made up of two things: an event definition (usually a keyword followed by a name or pattern), and an optional condition which must be satisfied before the actions in the rule body are executed.

The rule body contains any number of local declarations and actions that are to be executed when the event in the rule header is encountered.

If the event defined in a rule header is encountered in an input document, and if the condition on that event is satisfied or evaluates to true, then the rule is said to "succeed", "be selected", "be triggered", or "fire". All this means is that the event in the input document has met all of the requirements defined in a particular rule header and, therefore, the actions in that rule body are executed.

If an event does not meet all of the requirements defined in a particular rule header, the rule simply "fails" and the actions in the rule body are not executed.

Rules can be placed into groups which can then be activated and deactivated anytime during the processing of an input document.

OmniMark currently provides the following types of rules:

Prerequisite Concepts
     About OmniMark
 
   
----

Top [CONTENTS] [CONCEPTS] [SYNTAX] [LIBRARIES] [SAMPLES] [ERRORS] [INDEX]

Generated: April 21, 1999 at 2:00:51 pm
If you have any comments about this section of the documentation, send email to [email protected]

Copyright © OmniMark Technologies Corporation, 1988-1999.