SNAX/HLS Application Programming Manual

SCOBOLX Applications
SNAX/HLS Programming Standards
104707 Tandem Computers Incorporated 1–13
Note how the definitions in WORKING-STORAGE are constructed to create data
structures containing the entire bodies of the verbs. The variable-length portions are
appended to the definitions by application-defined text. In this way, the actual RU-
size limits, which are application-dependent, are under your control. Later, in the
PROCEDURE DIVISION, the SEND MESSAGE statement names the request structure
and provides the information necessary to discriminate among possible responses. In
this example, the responses can be SEND-DATA or RECEIVE-DATA. In a real
application, each possible reply must be itemized.
The TIMEOUT clause directs Pathway and SNAX/HLS to cooperate in interrupting
the SEND MESSAGE function, if it is not finished after 20 seconds. Note that this time
limit does not apply to the SNAX/HLS action—that is, the SEND portion of the
SEND-AND-RECEIVE-DATA verb.
The ESCAPE ON UNSOLICITED MESSAGE directs Pathway to interrupt the SEND
MESSAGE function upon the arrival of an unsolicited message. After processing it,
this example either notes that the original request was completed, or goes to
wait-for-completion to wait for the end of the send portion of the
SEND-AND-RECEIVE-DATA request.
TAL Applications SNAX/HLS can be viewed either as a server or a device from TAL applications. The
discussion below pertains to either view.
HLSDDT—TAL Copybook The copybook HLSDDT contains data definitions that standardize and simplify access
to SNAX/HLS for TAL application programs. The copybook provides definitions for:
Verb names and codes
Return names and codes
Data-type names and codes
Request and reply structures
User-exit structures
The HLSDDT file should never be sourced into your program in its entirety. Only the
needed sections should appear in source statements.
Section VERB^CODE^DEFINITIONS
Use the following statement to include the VERB^CODE^DEFINITIONS section of the
copybook in your program:
?source HLSDDT( verb^code^definitions )
It provides the basic value definitions for verbs. For example, the verb code for the
OPEN-SESSION request is defined by:
LITERAL verb^open^session = 1;
All verb codes are literals named
VERB^xxx
. The lowest value used for verbs is
VERB^^FIRST, and the highest value is VERB^^LAST.