MessagesOutImpl.mesa
Copyright © 1985 by Xerox Corporation. All rights reserved.
Russ Atkinson, March 7, 1985 2:31:57 pm PST
DIRECTORY
MessagesOut USING [],
MessageWindow USING [Append],
IO USING [PutRope, STREAM],
Process USING [CheckForAbort],
Rope USING [ROPE];
MessagesOutImpl: CEDAR MONITOR
IMPORTS MessageWindow, IO, Process
EXPORTS MessagesOut
= BEGIN
ROPE: TYPE = Rope.ROPE;
STREAM: TYPE = IO.STREAM;
PutRopes: PUBLIC ENTRY PROC [stream: STREAM, r1,r2,r3,r4: ROPENIL] = {
ENABLE UNWIND => NULL;
IF stream # NIL THEN {
IO.PutRope[stream, "\n"];
IF r1 # NIL THEN IO.PutRope[stream, r1];
IF r2 # NIL THEN IO.PutRope[stream, r2];
IF r3 # NIL THEN IO.PutRope[stream, r3];
IF r4 # NIL THEN IO.PutRope[stream, r4];
};
Process.CheckForAbort[];
};
PutMsg: PUBLIC ENTRY PROC [r1,r2,r3,r4: ROPENIL] = {
ENABLE UNWIND => NULL;
MessageWindow.Append[r1, TRUE];
IF r2 # NIL THEN MessageWindow.Append[r2, FALSE];
IF r3 # NIL THEN MessageWindow.Append[r3, FALSE];
IF r4 # NIL THEN MessageWindow.Append[r4, FALSE];
Process.CheckForAbort[];
};
END.