DEFINITION MODULE OutFile;

(* contains formatting number output routines*)
(* taken from the Lilith Handbook  13.1.1984 P. Fink *)
(* last change :   25.04.85 *)

FROM SYSTEM       IMPORT WORD, ADDRESS;
FROM M2Files      IMPORT File;
FROM RealTerminal IMPORT RFormat; (*= (RFixed, RFloat, RAuto);*)

EXPORT QUALIFIED FWrite, FWriteLn, FWriteT, FWriteI, FWriteC, FWriteH,
  FWriteAC, FWriteAH, Fdumphex, FWriteR;

PROCEDURE FWrite  (f: File; ch: CHAR);
PROCEDURE FWriteLn(f: File);
PROCEDURE FWriteT (f: File; VAR s: ARRAY OF CHAR; length: CARDINAL);
PROCEDURE FWriteI (f: File; value: INTEGER; length: CARDINAL);
PROCEDURE FWriteC (f: File; value: CARDINAL; length: CARDINAL);
PROCEDURE FWriteH (f: File; value: WORD; length: CARDINAL);

PROCEDURE FWriteAC (f: File; value: ADDRESS; length: CARDINAL);
PROCEDURE FWriteAH (f: File; value: ADDRESS; length: CARDINAL);

PROCEDURE Fdumphex
   (f: File; VAR title: ARRAY OF CHAR;
        start: ADDRESS; length: CARDINAL; printadr: ADDRESS; linelength: CARDINAL);
   (* note: printadr = displayed addr *)

PROCEDURE FWriteR (f: File; value: REAL; length,dec: CARDINAL; fmt: RFormat);

END OutFile.

