Previous Topic: Syntax of Selected ADDRESS EPI WordsNext Topic: EPI Host Command Descriptions


REXX Use of the Virtual Terminal Temporary Ownership Mechanism

For some operations, you should consider a virtual terminal as a serially reusable resource. For example, when two REXX programs use the same virtual terminal to issue a sequence of OMEGAMON commands, problems occur if both programs try to issue the commands at the same time. The mechanism of temporary ownership exists to alleviate this type of problem. Temporary ownership basically locks the terminal to a specific program until it is released. Ownership is either of the following:

Implicit

As the REXX program is being run, virtual terminal ownership is implicitly obtained whenever the program issues a command requiring the virtual terminal. Ownership is released as soon as the command has executed.

Explicit

A REXX program can first explicitly issue the ENQ or BIND command to establish virtual terminal ownership, and then use the virtual terminal for a series of commands, and finally issue the DEQ or UNBIND command to release ownership.