Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Operating System Utilities /
Chapter 6 - Queue Utilities / Queue Utilities Reference
Routines /


Enqueue

You can use the Enqueue procedure to add elements directly to an operating-system queue or a queue that you create.

PROCEDURE Enqueue (qElement: QElemPtr; qHeader: QHdrPtr);
qElement
A pointer to the queue element to add to a queue.
qHeader
A pointer to a queue header.
DESCRIPTION
The Enqueue procedure adds the queue element specified by qElement parameter to the end of the queue specified by the qHeader parameter. The specified queue header is updated to reflect the new queue element.

SPECIAL CONSIDERATIONS
Because interrupt routines are likely to manipulate operating-system queues, interrupts are disabled for a short time while the specified queue is updated. You can call the Enqueue procedure at interrupt time. Whenever possible, use the installation routines listed in Table 6-2 on page 6-10 instead of the Enqueue procedure.

ASSEMBLY-LANGUAGE INFORMATION
The registers on entry and exit for the Enqueue procedure are
Registers on entry
A0Pointer to the queue element to be added
A1Pointer to the queue header
Registers on exit
A1Pointer to the queue header

SEE ALSO
For a description of the QElem record, see page 6-14; for a description of the QHdr record, see page 6-13.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996