DEFINITION MODULE Defaults;
(*
    Title    :  Defaults
    LastEdit :  Wed Dec 19 17:25:36 1984
    Author   :  Graham Toal
    Acorn Computers VLSI Design Aids Group
*)
FROM Dict        IMPORT DICT;
FROM nString      IMPORT STRING;
FROM Streams     IMPORT STREAM;
EXPORT QUALIFIED ReadTechnology, Update,
                 Dictionary, 
                 Layer, LayerID, LayerName,
                 MaxLayers,
		 LastUsedLayer,
                 MinWidth, Micron, Lambda,
                 Contents;
CONST  MaxLayers = 32;                              (* Total no. poss. *)
VAR    LayerName : ARRAY [0..MaxLayers-1] OF STRING;
                                              (* Map enum. type onto string *)
   LastUsedLayer : [0..MaxLayers-1];          (* Not all layers are used    *)
        MinWidth : ARRAY [0..MaxLayers-1] OF INTEGER;
                                              (* DRC information            *)
          Micron : INTEGER;                   (* Hard implementation value  *)
          Lambda : INTEGER;                   (* Soft implementation value  *)

  Contents  :DICT; (* the master table of contents: all entries are DICTs   *)
                   (* This table has global state.                          *)
PROCEDURE ReadTechnology(Stream :STREAM);
   (* Read a technology file to update dictionary entries                   *)
   (* Implies call to 'Update' below.                                       *)
PROCEDURE Update();
   (* Make all variables reflect entries in tables                          *)
PROCEDURE Dictionary(DictName : ARRAY OF CHAR) : DICT;
   (* Find a globally visible technology table.                             *)
   (*  Dicts currently valid are: Value Text Layer MinWidth                 *)
   (*  'Value' holds integer values "lambda" and "micron"                   *)
   (*  'Text' holds string values only.                                     *)
PROCEDURE LayerID(Name: STRING): CARDINAL;
PROCEDURE Layer(Name: ARRAY OF CHAR): CARDINAL;
   (* Map layer names onto enumerated 'Layer' type                          *)
END Defaults.
