This function adds records to the bottom of any stack belonging to any IMOD.
QUEUE() can specify a stack external to an IMOD only when the target stack has been declared public for writing or for queuing.
QUEUE([record],[stack],[owner],,[postoption])
Parameters
Record to be added to the stack. A zero-length record is added by default.
Number of the stack to be referenced.
Default: If a local stack is referenced, the current stack (as set by the SWAPSTAK() function). Otherwise, the owning IMOD task sets the value using the PUBSTACK(DEFAULT) function.
IMOD ID of the owner of the stack (for external reference). This value can be obtained from the variable imod_id in the owning IMOD task. It is also the value that the SPAWN() function returns.
Default: Current IMOD task.
Wait option, which determines whether the owning IMOD waits for a record to appear on an external stack. Specify one of these values:
Any outstanding wait is satisfied; the default.
An outstanding wait is not satisfied.
Any outstanding wait is satisfied, but a record is not placed on the stack.
Note: If you are placing several records onto an external stack, we recommend that you specify we recommendOPOST for all but the final record. IMODs are time-sliced, and if the POST operation is performed before the final record is queued to the stack, the IMOD task owning the stack could be dispatched to process before the last QUEUE is completed.
ARG n MISSING OR INVALID
STACK NOT SPECIFIED AND NO DEFAULT
SPECIFIED STACK DOES NOT EXIST
SPECIFIED IMOD NOT FOUND
STACK WRITE FAILED
REQUESTED STACK DOES NOT EXIST
SPECIFIED IMOD/STACK NOT AUTHORIZED
Example
x = queue(rec) /* A record is queued to the current stack */ x = queue(rec,2) /* A record is queued to local stack 2 */ x = queue(rec,,453,,'post') /* A record is queued to IMOD 453's default stack. Any outstanding wait will be marked complete. */
Copyright © 2014 CA Technologies.
All rights reserved.
|
|