SNAX Creator-2 Configuration and Control Manual

Generating SERVER and MESSAGE Values
Configuration Examples
C–2 117143 SNAX Creator-2 Configuration and Control Manual
Using the [#num] Function This example shows how to derive values for the attributes PATHMON and
PROGRAM from logon user data using the [#num] function. The application named
mypath is configured as follows:
ADD APPL $CREA.C-mypath
, METHOD PATHWAY
, PATHMON [#1]
, PROGRAM [#2]
If the user data is:
$pmon, prog1
then the PATHMON attribute is assigned the value $pmon, and the PROGRAM
attribute is assigned the value prog1.
Using the [#KEYWORD]
Function
This example shows how to derive the PATHMON and PROGRAM attribute values
from user data using the [#KEYWORD] function. The application named mypath is
configured as follows:
ADD APPL $CREA.C-mypath
, METHOD PATHWAY
, PATHMON "[#KEYWORD Name]"
, PROGRAM "[#KEYWORD Application]"
, MAXARGS 2
SNAX Creator-2 will search the user data for the keywords Name and Application
and their values.
Suppose the user data is:
Name $pmon1, Application appl1
Then the [#KEYWORD] function searches this data for the keyword Name and assigns
the value of the subsequent string up to a comma or end of data (leading and trailing
blanks are discarded). The Application value is assigned in a similar manner.
Hence the PATHMON attribute is evaluated as $pmon1, and the PROGRAM attribute
is evaluated as appl1.
If the keywords or their values are omitted, the [#KEYWORD] function assigns a blank
value to the PATHMON and PROGRAM attributes, and the logon fails. The
MAXARGS value on the APPL definition guarantees that any extraneous data causes
the logon attempt to fail.
Generating SERVER
and MESSAGE Values
The following examples specify values for the MESSAGE and SERVER attributes for
server-started applications. The values can be specified as literal values (as in the first
example) or built-in functions and entries can be used.
Using Literal Values This example specifies literal values for the SERVER and MESSAGE attributes (other
than the logon terminal name).