-- Edge.mesa -- Last changed by Doug Wyatt, September 14, 1980 1:24 PM DIRECTORY Vector USING [Vec], Pipe USING [Handle]; Edge: DEFINITIONS = { Handle: TYPE = LONG POINTER TO Object; -- Client interface for an Edge object New: PROC[v0,v1: Vector.Vec] RETURNS[Handle]; NewPipe: PROC[self: Handle, ipipe,opipe: Pipe.Handle] RETURNS[Pipe.Handle] = INLINE { RETURN[self.procs.NewPipe[self,ipipe,opipe]] }; Free: PROC[selfPtr: LONG POINTER TO Handle] = INLINE { self: Handle=selfPtr^; selfPtr^_NIL; self.procs.Free[self] }; -- Actual representation for an Edge interface Object: PRIVATE TYPE = RECORD [ procs: LONG POINTER TO READONLY Procs, data: LONG POINTER TO Data ]; Procs: PRIVATE TYPE = RECORD [ NewPipe: PROC[self: Handle, ipipe,opipe: Pipe.Handle] RETURNS[Pipe.Handle], Free: PROC[self: Handle] ]; Data: PRIVATE TYPE; EdgeImpl: PROGRAM; }.(670)