TO)
The DESL Global Options
There are several options which are termed global because they have the same meaning regardless of the command they are being applied to. Global options are applicable to all commands which allow options and which are entered in the command-line mode of input.
The current list of global options is :
Global options are not allowed within a section of input which is activated via the read- or use-type constructs.
If the read- or use-type construct needs to be used, the desired global options should to be entered prior to or after the read/use import of input lines.
Global options followed by their associated arguments should be the first and the only items on an input line unless specifically stated otherwise below.
The following is a summary of the global options. Following each global option is the syntax of any required or optional argument list.
TO1)
alias
To temporarily change the spelling of a option.All original option spellings are restored after the execution of the current command. The alias structure has to be encountered before the first use of the changed option.
Syntax : alias newkw oldkw
where :
Aliasing is most useful when a option and a option argument would normally have had the same name.
To abort input, not process the current command,
save all input in a save set and cause DESL to
solicit a new command. (quit also
aborts input but does not save the input thus far.)
Syntax : cancel
Note : cancel can appear anywhere before go
Example : cancel
Cancel can save you typing. If you realize, as you are typing input
to a command, that you, for whatever reason, should not continue with
the command, but would, nevertheless, like to salvage the input
you have
entered thus far, entering cancel will abort the command
and save
the input to a save set buffer, which you can later use as
input to the same or another command.
Please see the documentation for the ifk option. It
discusses the ifk, elsek, and endifk options.
Please see the documentation for the ifk option. It
discusses the ifk, elsek, and endifk options.
To remove the last one or more lines which have been entered as
input for the current command.
Syntax : erase (#)
where :
# is an optional number of lines to erase. The
default number is 1.
Example : erase 3
This can let you avoid having to use cancel. Just eliminate the
most previous line(s) you just typed incorrectly and then continue
entering input.
Signals the end of input for current command. After being
encountered, the appropriate DESL function begins to execute if
all input has been judged syntactically correct and sufficient.
Syntax : go
Note : go can appear anywhere on the input line
Example : go
When you enter this option plus a carriage return, it's
all over but the shouting. DESL goes off and attempts to
execute the command you have specified.
The DESL ifk global option is a special option which serves to
logically determine whether a block of DESL command input will be used
or not. It is a conditional option which is a part of a more
complete ifk elsek endifk structure which can be included in
any DESL command's input stream.
There can be up to 10 sets of conditional argument phrases
associated with the ifk option. Each conditional phrase
must be separated from the other by a conjunction.
If the conditions following ifk, considered altogether,
accounting for ALL conjunctions and processing from
left to right, are TRUE then any command input
immediately following the ifk option, up to and including the
input immediately preceding either the next elsek or
endifk, or the end of input, whichever is encountered first,
will be processed.
An ifk block CANNOT be nested within another ifk block.
After processing the pertinent section of command input, control jumps to
the input immediately following the closing endif option.
If one or more of the conditions following the ifk, considered
altogether, accounting for ALL conjunctions and processing from
left to right, are FALSE then control jumps to the next elsek,
or endifk option, whichever is encountered first. If
an elsek command has been jumped to, the conditions included
in this command are evaluated and processing continues as it did
after the evaluation of the opening ifk statement. If an
elsek
option has been jumped to, any DESL input immediately
following that elsek option, until the next endif option
will be executed, after which control will jump to the input
immediately following the closing endifk command.
Examples of two ifk else endifk structures which could be
be contained in a command input file or macro is the following :
print
ifk *V1 eq 10 or *N2 eq run10
files run9 run10 run11
elsek
files run9 run11
endifk
names alpha beta cl cd cm
format g12.5 lines 999 go
print
ifk exists file run10 then
files run9 run10 run11
elsek
files run9 run11
endifk
names alpha beta cl cd cm
format g12.5 lines 999 go
There are two fundamental types of condition syntaxes which can
be used :
In Example 2,
the second type of ifk option involves checking to see
if one or more files either are ALL in existence or are ALL NOT in
existence. The resulting True/False state is set accordingly.
Then, for EITHER type of ifk command, based on this
resulting state, the following block of input sections are processed or
skipped.
The structure of a condition, used with the first type ifk
option, (1) above, can be either of the following :
[Top][Bottom]
TO2)
cancel
[Top][Bottom]
TO21)
elsek
[Top][Bottom]
TO22)
endifk
[Top][Bottom]
TO3)
erase
[Top][Bottom]
TO4)
go
[Top][Bottom]
TO42)
ifk
Example 1.
Example 2.
In Example 1,
the first type of ifk option evaluates the True/False
state of each condition, logically links them, from LEFT to RIGHT,
via the expressed conjunction(s) and or or and determines
an overall True/False state. For this type of if option
up to ten (10) conditions can be specified.
where, "cond1", etc. represent "conditions".
where, "fn1", etc. represent file names
. [*N# ] [= ] [*N# ] or [*V#] [= ] [*V#]
. [str] [eq] [str] [##] [eq] [##]
. [ne] [ne]
. [ge]
. [gt]
. [> ]
. [le]
. [lt]
. [< ]
A condition involves EITHER name-type OR value-type arguments
To list the options which are permitted (required/optional)
for the current command.
Syntax : options/opt
Example : optn
To abort input, not process the current command, and cause DESL to
solicit a new command. (cancel also aborts input and saves the input
thus far.)
Syntax : quit
Note : quit can appear anywhere BEFORE go
Example : quit
If you get stuck or decide you just do not want to continue,
enter quit plus a carriage return. You'll be back at the DESL>
prompt ready to enter the same or a new command.
To cause a group of lines to be read into the current command
input sequence at the current location from an alternate file.
Additionally, if read is
specified and DESL is in the
purely interactive mode a chance
to
edit the read-in file contents is given before the lines
are inserted into the current input sequence. If DESL is not
in the purely-interactive mode no chance to edit the read-in file
will be given.
The file read into DESL via read or readn cannot, itself
contain another form of the read option.
There should be no blank lines in a file to be accessed
via read/readn.
If readn is specified, no chance to edit the read-in file will be given
regardless of the current DESL mode.
Syntax : read(n) filename
where :
file_name is a required file name
Note : read(n) option phrase can appear anywhere on the line
Example : ... read fitinpt
Use the read(n) global option to avoid typing. One or more prepared
input files can be referenced during the input to a DESL command.
To cause a group of lines to be read into the current command
input sequence
at the current location from a named section on an alternate file.
If reads is specified and DESL is in the
purely interactive mode a chance
to
edit the read-in file section contents is
given before the lines are inserted into the current input sequence.
The file read into DESL via read or
readn cannot, itself contain another
form of the read option.
There should be no blank lines in a file to be accessed
via reads/readsn.
If readsn is specified, no chance to edit the read-in file section will
be given regardless of the current DESL mode.
Syntax : reads(n) filename sectionname
where :
file_name is a required file name
section_name is a required section name
Note : "reads(n)" option phrase can appear anywhere on the line
Example : reads fitinpt sect1
Use the reads(n) global option to avoid typing. One or more prepared
input file sections can be referenced during the input to a DESL command.
A single input file can contain multiple individually-referenceable
sections.
An example of a sectioned input file "fitinpt" :
.
.
.
section sect1
.
.
.
(any command input)
.
.
.
section sect2
.
.
.
(any command input)
.
.
.
To establish the name of the referenceable set of input which is currently
being entered. (See "use(n)" for a description of how to read this type of
saved input back in.) The default name of the input set is "save####",
where #### is a unique 4-digit number.
Syntax : save savnam
where :
"savnam" is the desired name of the saved set of input
Note : "save" option group can appear anywhere on the line
Example : ... save savfit1 ...
All input, regardless of its origin, will be saved in a "save" buffer
by SOME name unless "quit" is entered. This global option just lets
you explicitly name the set rather than getting the default type name.
Save sets ONLY exist within a DESL session : when the session ends the
save sets in the internal buffer are gone. These "save" sets can, however,
be moved out of the save buffer and copied to one or more files.
The "saveinput" command provides this capability.
To allow a review of the existing referenceable sets of saved input.
Syntax : see ( save_set_name )
where :
"save_set_name" is an optional argument which can name the particular saved
input set to review. If no saved set is named, all of the save-set
names and the names of their originating commands will be displayed.
Example : see save0003
As a session proceeds, many "save" sets of input can be created. If
you know that a while ago you entered a set of input which is almost like
a set you need to enter again now, "see" provides the means for examining
one or more of these sets, without using them, to find the one you may need
to modify and reuse.
To cause a group of lines to be read into the current command input sequence
at the current location from a named or unnamed set of saved input.
If "use" is specified, a chance to
edit the named/unnamed saved set of
input is given before the lines are inserted into the current input
sequence. If "usen" is specified, no chance to edit the named/unnamed
saved set of input is given before the lines are inserted into the
current input sequence.
Syntax : use(n) ( save_set_name )
where :
save_set_name is an optional name of a previously created set of input.
If a save set is named the named save set is attempted to be accessed
from the internal save buffer. If no save set is named
the most recent set of input from the same command
is searched for. If no save set from the same command
is found, the most recent set from any command is
used. If these are no save sets in existence, a reply from DESL
to that effect will be made.
Note : "use(n)" option phrase can appear anywhere on the line
Example : usen save0003 ...
"use" provides the means to quickly "iterate" on an input set until
the desired results are achieved. The "use" and "read" global options
are similar : the "use" input comes from an internal buffer and the
"read" input comes from a file.
[Top][Bottom]
TO5)
options/opt
[Top][Bottom]
TO6)
quit
[Top][Bottom]
TO7)
read/readn
[Top][Bottom]
TO8)
reads/readsn
[Top][Bottom]
TO10)
save
[Top][Bottom]
TO11)
see
[Top][Bottom]
TO12)
use/usen
30 Research Drive
Hampton, VA 23666
Voice: (757) 865-1400
Toll Free: (800) 288-3998
FAX: (757) 865-8177
© 1999 ViGYAN, Inc.