Meta-Wlp definition
Meta-Wlp definition
Revision 2.
- The prime directive for the Meta-Wlp definition is that it be
easily parsed by PERL.
- Directives have format hash-mark in column 1 followed immediately
by the keyword, followed immediately by a colon. Directive continues
until the End-Of-Line.
- Two parse tokens are distinguished: whitespace and End-Of-Line.
White space is defined by PERL's \s.
- The file is introduced on line 1 by
#Meta-Wlp:
.
- The value setting directive has form,
#Macro: name value
.
. Macro evaluation
occurs on directive lines only. Eval is used to force a macro
evaluation that is placed into the text.
- A macro on a directive line is expanded when its name
appears between dollar signs,
$NAME$
.
- The label directive has form,
#:
or (labelled form) #:label
.
This generally closes blocks opened by a command directive,
the labelled form is specific, the unlabelled form is a wildcard.
- Command Verbatim.
#Verbatim: label
. The
end of the verbatim block is the label directive with
matching label, #:label
.
Between these two lines the data is taken verbatim and the
hash-mark in column 1 has no special significance.
The label also serves as a tag for the verbatim text.
- Command Shuffle.
#Shuffle: label [ label]*
.
For each label, the end of a shuffle is a label directive
#:label
. After all labels have been matched,
in the order listed in the Shuffle command, the shuffle
block is completed. The second and succeeding blocks are
shuffled, and the first block is placed at the end. The blocks
are placed in a radio-button form, with name Guess returning
value label.
- Line escape:
#Not-Next: n
. n a non-negative
integer, default 1. The next n lines are literal.
- Digression command:
#Digression: labelA labelB ...
.
Between the command and #:labelA
is the anchor for
the digression text which follows the labelA, up to
#:labelB
. If many digressions are given, one at random is
picked each time the anchor is activated.
Burt.Rosenberg@cs.miami.edu
Return to Web Learning Pages