MergeControl.mesa
Copyright (C) Xerox Corporation 1984, 1985, 1986. All rights reserved.
Last edited by Jacks 16-Jul-85 8:14:35
Tim Diebert: October 23, 1986 4:41:32 pm PDT
<<This interface is used to control the merge operation.>>
DIRECTORY
NSString USING [String],
PrintingTypes USING [Option],
PrintQueue USING [ObjectStatus, QueueObjectHandle],
Process USING [Priority],
PSAsyncMsg USING [Proc];
MergeControl: CEDAR DEFINITIONS = BEGIN
TraceLevel: TYPE = {none, terse, verbose};
WaitChoice: TYPE = {wait, dontWait};
NotifyCode: TYPE = {noResources, other};
NotifyProc: TYPE = PROCEDURE [queueObject: PrintQueue.QueueObjectHandle, code: NotifyCode, continuable: BOOLEAN] RETURNS [keepGoing: BOOLEAN];
In some cases the client is notified of problems found while merging and may continue (if continuable) or abort the document.
CancelProc: TYPE = PROCEDURE [docName: NSString.String,
docQueueStatus: PrintQueue.ObjectStatus];
Procedures
Init: PROCEDURE [currentOption: PrintingTypes.Option,
priority: Process.Priority,
notifyProc: NotifyProc, --proc called to notify client of problems found while merging.
putAsyncMsgFromKey: PSAsyncMsg.Proc];
called only once
Start: PROCEDURE;
Enables (paused or stopped) merging and returns.
Stop: PROCEDURE [status: PrintQueue.ObjectStatus, canceledWhileMerging: CancelProc ← NIL];
Disables merging and returns; document in progress is given the status specified and put on the appropriate queue. If the document is put on the aborted queue, the cancel proc is called.
Stopped: PROCEDURE [wither: WaitChoice ← dontWait] RETURNS [BOOLEAN];
IF wither=wait, returns TRUE when merging is stopped.
IF wither=dontWait, return immediately.
Status: PROCEDURE RETURNS [merging: BOOLEAN]; --returns TRUE if a document is being merged.
ModifyTraceLevel: PROCEDURE [trace: TraceLevel];
END. -- of MergeControl
LOG when/who/what
16-Oct-84 11:09:57 - Jacks - Created.
12-Jun-85 18:05:34 - Jacks - Added copyright notice.
16-Jul-85 8:14:24 - Jacks - PSAsyncMsg interface change.