<> <> <> <> <> <> DIRECTORY DB USING [Domain, Entity, Relation, Relship], IO USING [STREAM], Rope USING [ROPE]; NutDump: CEDAR DEFINITIONS = BEGIN OPEN DB, IO, Rope; <<**************************************************>> <> <<**************************************************>> DumpToFile: PROC[ segment: ROPE, fileName: ROPE _ NIL, dl: LIST OF Domain _ NIL, rl: LIST OF Relation _ NIL, complement: BOOLEAN _ FALSE, entityCentric: BOOLEAN _ FALSE]; <> DumpAll: PROC[segment: ROPE, fileName: ROPE _ NIL] = INLINE {DumpToFile[segment, fileName, NIL, NIL, TRUE]}; LoadFromFile: PROC[dumpFile: ROPE _ NIL, DBFile: ROPE _ NIL]; <> <<**************************************************>> <> <<**************************************************>> OpenFile: PROC[fileName: ROPE] RETURNS[STREAM]; CloseFile: PROC[fileStream: STREAM]; <> WriteSchema: PROC[s: STREAM, dl: LIST OF Domain, rl: LIST OF Relation]; WriteDomain: PROC[s: STREAM, d: Domain, refs: BOOL_ FALSE]; -- writes entities in domain WriteEntity: PROC[s: STREAM, e: Entity]; -- writes a particular entity WriteRelation: PROC[s: STREAM, r: Relation]; -- writes all the relships of the relation WriteRelship: PROC[s: STREAM, r: Relship]; -- writes a particular relship END . . .