--LispToolOps.mesa
--Created by
--   JFung.PASA	  	19-Sep-83 17:19:12

--last edited by
--   JFung.PASA	   	18-Jan-84 10:25:38



DIRECTORY
     File,
     FileTransfer,
     FormSW,
     Profile,
     ToolWindow,
     Volume USING [ID, nullID],
     Window USING [Handle];



LispToolOps: DEFINITIONS =
     BEGIN

     -- TYPEs
     Indicator: TYPE = {off, left, right};
     VolHints: TYPE = RECORD [names: SEQUENCE length: CARDINAL OF LONG STRING];
     PasswordArray: TYPE = RECORD [names: SEQUENCE length: CARDINAL OF LONG STRING];
     SizeHints: TYPE = RECORD [names: SEQUENCE length: CARDINAL OF CARDINAL];

     DocType: TYPE = {general, errorMsg};
     ServerType: TYPE = {IFS, NS};

     DataHandle: TYPE = LONG POINTER TO Data;
     Data: TYPE = MACHINE DEPENDENT RECORD [
          -- Message subwindow stuff
          msgSW(0): Window.Handle ← NIL,
          -- File subwindow stuff
          fileSW(2): Window.Handle ← NIL,

          -- Form subwindow stuff
          -- Note: enumerateds and booleans must be word boundary
          -- aligned as addresses for them must be generated
          --formSW: Window.Handle ← NIL,
          paramSW(4): Window.Handle ← NIL,
          commandSW(6): Window.Handle ← NIL,

          busy(8): BOOLEAN ← FALSE,  -- command is running
          userName(9): LONG STRING ← NIL,
          userPassword(11): LONG STRING ← NIL,
          domainName(13): LONG STRING ← NIL,
          organizationName(15): LONG STRING ← NIL,
          filePathName(17): LONG STRING ← NIL,

          volName(19): LONG STRING ← NIL,
          volHints(21): LONG POINTER TO VolHints ← NIL,
	  volPassword(23): LONG STRING ← NIL,
	  --passwordPtr(25): LONG POINTER TO PasswordArray ← NIL,
          --volHintsReady(23): BOOLEAN ← FALSE,
          --volHintsBusy(24): BOOLEAN ← FALSE,

          vMemSize(25): File.PageCount ← 0,
          fileTable(27): LONG POINTER TO SizeHints ← NIL,
          connection(29): FileTransfer.Connection ← NIL,
          indicator(31): Indicator ← left,
	  docType(32): DocType ← general,
	  fileServer(33): ServerType ← NS];


     -- Variable declarations

     --privateHeap: UNCOUNTED ZONE ← NIL;
     --debug: BOOLEAN;
     toolData: DataHandle;
     windowHandle: Window.Handle;


     BootStuff: PUBLIC PROCEDURE[];
     -- exported from  ILTBootImpl;

     --ClearCommandSubwindow: PUBLIC PROCEDURE[];
     -- exported from  ILTBootImpl;

     --ClearFileSubwindow: PUBLIC PROCEDURE[];
     -- exported from  ILTBootImpl;

     --ClearMsgSubwindow: PUBLIC PROCEDURE[];
     -- exported from  ILTBootImpl;

     Confirm: PUBLIC PROCEDURE RETURNS [okay: BOOLEAN];
     -- exported from  LispToolImpl;
     
     --DisplayCommandSubwindow: PUBLIC PROCEDURE[];
     -- exported from  LispToolImpl;
     
     --DisplayEmpty: PUBLIC ToolWindow.DisplayProcType;
     -- exported from  LispToolImpl;


     DisplayFileSize: PUBLIC PROCEDURE [size: File.PageCount];
     -- exported from  LispToolImpl;

     
     --DisplayIndicator: PUBLIC ToolWindow.DisplayProcType;
     -- exported from  LispToolImpl;

     DisplayWriteUp: PUBLIC PROCEDURE;
      -- exported from  ILTHelpImpl;   
    
     EraseProc: PUBLIC PROCEDURE [vName: LONG STRING];
     -- exported from  ILTEraseImpl;

     FloppyStuff: PUBLIC PROCEDURE [];
     -- exported from  ILTFloppyImpl;

     GetFileSize: PUBLIC PROCEDURE[] RETURNS [pageCount: File.PageCount];
     -- exported from  ILTVMemImpl;

     GetVolumeID: PROCEDURE [volumeName: LONG STRING]
          RETURNS [volumeID: Volume.ID ← Volume.nullID, volumeOpen: BOOLEAN];
     -- exported from  ILTEraseImpl;

     InstallProc: PUBLIC PROCEDURE [vName: LONG STRING];
     -- exported from ILTInstallImpl;
     
     InvertIndicator: PUBLIC PROCEDURE [];
     -- exported from LispToolImpl;

     ListLogicalVolumes: PUBLIC PROCEDURE RETURNS[nVols: CARDINAL];
     -- exported from  LispToolImpl;

     LispToolActivate: PUBLIC PROCEDURE[];
     -- exported from  LispToolImpl;

     LoginProc: PUBLIC PROCEDURE[];
     -- exported from ILTLoginImpl;

     MakeUserCM: PUBLIC PROCEDURE[];
     -- exported from ILTUserCMImpl;

     ProfileToolActivate: PUBLIC PROCEDURE[];
     -- exported from  ILTSetProfileImpl;

     ScavengeProc: PUBLIC PROCEDURE [vName: LONG STRING];
     -- exported from ILTScavengeImpl;

     SetVMemFileSize: PUBLIC PROCEDURE [pageCount: File.PageCount];
     -- exported from ILTVMemImpl;

     SetVolumeProc: PUBLIC PROCEDURE [vName: LONG STRING] RETURNS [BOOLEAN];
     -- exported from ILTInstallImpl;

     END...