Each process has associated with it eight Boolean task attributes named SW1 through SW8. These task attributes have no intrinsic meaning, but serve to convey application-defined information to a process. Operators can modify the values of these attributes for a running process by using the SW (Switches) system command. For example, the following commands set and reset the SW1 attribute of the process with mix number 4875:
4875 SW1 TRUE 4875 SW1 FALSE
There is no event, equivalent to EXCEPTIONEVENT or ACCEPTEVENT, to inform the process that one of the switch values has changed. Instead, to detect that one of the switch task attributes has changed value, the process must periodically interrogate the value of that switch.
Alternately, you can establish a convention whereby the operator is expected to follow each SW command with a HI or AX command to notify the process to interrogate the switch values. For example, the following ALGOL statements cause a program to interrogate SW1 and SW2 whenever an AX command is received:
INTERRUPT SWITCHER;
BEGIN
IF MYSELF.SW1 THEN
<statements>
ELSE IF MYSELF.SW2 THEN
<statements>
END;
ATTACH SWITCHER TO MYSELF.ACCEPTEVENT;The operator can also use the SW command to display the current values of the SW1 through SW8 task attributes of a process. The following is an example of a command that interrogates these attributes for mix number 4873, and the resulting display:
4873 SW
SWITCH VALUES FOR 4873:
SW 1 = FALSE
SW 2 = FALSE
SW 3 = FALSE
SW 4 = TRUE
SW 5 = FALSE
SW 6 = FALSE
SW 7 = FALSE
SW 8 = TRUE
