-- DLoadState.mesa
-- Last Modified by Sandman,  October 7, 1980  12:22 PM 

DIRECTORY
  BcdOps USING [BcdBase],
  MachineDefs USING [ConfigIndex, FSHandle, GFTIndex];

DLoadState: DEFINITIONS =
  BEGIN OPEN MachineDefs;
  
  state: FSHandle;
  offset: CARDINAL;

  MapConfigToReal: PROCEDURE [cgfi: GFTIndex, config: ConfigIndex]
    RETURNS [rgfi: GFTIndex];
  MapRealToConfig: PROCEDURE [rgfi: GFTIndex]
    RETURNS [cgfi: GFTIndex, config: ConfigIndex];

  Map: TYPE = DESCRIPTOR FOR ARRAY OF GFTIndex;
  
  GetMap: PROCEDURE [config: ConfigIndex] RETURNS [map: Map];
  ReleaseMap: PROCEDURE [map: Map];
  
  Acquire: PROCEDURE RETURNS [nbcds: ConfigIndex];
  Release: PROCEDURE;
  Invalid: SIGNAL;
  
  AcquireBcd: PROCEDURE [config: ConfigIndex] RETURNS [bcd: BcdOps.BcdBase];
  ReleaseBcd: PROCEDURE [bcd: BcdOps.BcdBase];
  
  EnumerationDirection: TYPE = {recentfirst, recentlast};
  
  Enumerate: PROCEDURE [
    dir: EnumerationDirection, proc: PROCEDURE [ConfigIndex] RETURNS [BOOLEAN]]
    RETURNS [config: ConfigIndex];
  
  Init: PROCEDURE;

  END....