DEFINITION Cookie; (* SJ *)

(* some procedures to work with the cookie jar *)

TYPE code* = ARRAY 5 OF CHAR;


PROCEDURE Available*() : BOOLEAN;

(* returns TRUE if there is a cookie jar *)


PROCEDURE Search*(Code : code; VAR Cont : S.PTR) : BOOLEAN;

(* seaches the cookie jar for an entry with code Code and returns TRUE if
   found. Cont then contains the value entered in the jar.
*)

PROCEDURE Entry*(Code : code; Cont : LONGINT) : BOOLEAN;

(* enters a cookie if there is a cookie jar. If there is no jar or it is
   full, FALSE is returned *)


PROCEDURE Delete*(Code : code);

(* deletes an entry in the cookie jar if found *)


END Cookie.