NET/MASTER Network Control Language (NCL) Reference Manual
Variable Lists Beginning With VARS
Verb Syntax and Variable Access Methods
106126 Tandem Computers Incorporated 11–11
Some examples of verbs that use VARS lists are: ASSIGN, DROP, EMSREAD, FILE
ADD, FILE GET, FILE PUT, FILE PUTGET, INTREAD, LOGREAD, MSGREAD,
PARSE, PAUSE, SECCALL, and VARTABLE. The following discussions have many
examples of VARS lists.
Specifying a Range of
Variables
You can specify a range of variables in a VARS list. Specifying a range of variables in a
VARS list allows you to specify a set of variables with a range of numeric suffixes.
This option affects how variable names are generated by the VARS list. It affects the
number of variables that are generated by the VARS list.
When you are specifying a range of variables, you must follow the variable name for
which you want to specify the range by an asterisk (*).
Here are the components of the VARS list that you use to specify a range of variables:
&[
variable
] * [ (
start1
,
end1
) ]
and
[ RANGE [ = ] (
start2
,
end2
) ]
Here is some terminology for the purpose of discussing the syntax of a
ranged-variable-specification
. The &[
variable
] * is called the
variable specification. The parts of the syntax that specify the start value of the range
and the end value of a range are shown by (
start1
,
end1
) and (
start2
,
end2
).
They are collectively called the range of the variable. The range that immediately
follows the variable specification is called the first range. The range that follows
RANGE is called the second range.
The syntax shows that a variable specification is mandatory when specifying a range
of variables. It shows that other components of a
ranged-variable-specification
are optional. It shows that you can use the
RANGE keyword to specify a second range.
Implicit in the syntax is the fact that you can specify a range of variables in four ways:
By omitting both the first and second range
By providing the first range, but omitting the second range
By omitting the first range, but providing the second range
By providing both the first and second range
The following discussion of
ranged-variable-specification
breaks up the
complete syntax description. It discusses generating and targeting
ranged-variable-specification
using each of these four methods. Before
discussing the four ways of specifying a range of variables, it discusses how a variable
name is constructed and explains how NCL determines the start and end values for a
range.