BridgeComm.mesa
Copyright Ó 1992 by Xerox Corporation. All rights reserved.
Demers, May 14, 1990 3:57 pm PDT
Peter B. Kessler November 2, 1987 3:55:08 pm PST
BridgeComm:
CEDAR
DEFINITIONS ~ {
ROPE: TYPE ~ Rope.ROPE;
NetworkStreamPair:
TYPE ~
RECORD [
in: IO.STREAM,
out: IO.STREAM
];
Error: ERROR [msg: ROPE];
GetRopeToEOM:
PUBLIC
PROC [nsp: NetworkStreamPair]
RETURNS [rope:
ROPE ¬
NIL];
Read to EOM and return chars read as a rope. Clear the EndOfStream condition.
! ABORTED
GetMsg:
PROC [nsp: NetworkStreamPair]
RETURNS [msg:
CHAR, arg:
ROPE];
! ABORTED, Error
PutMsg:
PROC [nsp: NetworkStreamPair, msg:
CHAR, arg:
ROPE ¬
NIL];
! ABORTED, Error
PutMsgWithReply:
PROC [nsp: NetworkStreamPair, msg:
CHAR, arg:
ROPE ¬
NIL]
RETURNS [ansMsg:
CHAR, ansArg:
ROPE];
! ABORTED, Error
PutMsgWithAck:
PROC [nsp: NetworkStreamPair, msg:
CHAR, arg:
ROPE ¬
NIL];
! ABORTED, Error
CloseHandshakeAction: TYPE ~ { none, initiate, reply };
CloseConnection: PROC [nsp: NetworkStreamPair, action: CloseHandshakeAction ¬ none];
}...