XTkFastAccessPrivate.mesa
Copyright Ó 1991 by Xerox Corporation. All rights reserved.
Created by Christian Jacobi, July 8, 1991 5:15:35 pm PDT
Christian Jacobi, July 10, 1991 6:27 pm PDT
Crazy internal module which is used to enable asynchronous stopping of paint processes of widgets.
DIRECTORY
Xl USING [TQ];
XTkFastAccessPrivate: CEDAR DEFINITIONS ~
BEGIN
It is very worth while to collect the ThreadQueues used to synchronize on, as typically there will be always the same ones used, and, the sets will be quite small.
The procedures in this interface do not monitor on the set used; this ought to be done by the caller.
This design is in part motivated by the desire to avoid memory allocations.
TQSet: TYPE = REF TQSetRep;
TQSetRep: TYPE;
Include: PROC [set: TQSet, tq: Xl.TQ] RETURNS [TQSet];
Returns same set with tq included.
Sometimes modifies set in place, sometimes allocates new ref.
Synchronize: PROC [set: TQSet];
Waits until all tq's in set have freed the lock once (however temporary), or, until time out occurs.
Returns set to free list: set MUST NOT be used any more.
END.