<<>> <> <> <> DIRECTORY Rope, SunRPC, UT, UTGetPut, JoinApp, JoinAppGetPut; JoinAppGetPutImpl: CEDAR PROGRAM IMPORTS SunRPC, UTGetPut EXPORTS JoinApp, JoinAppGetPut = BEGIN Handle: TYPE = SunRPC.Handle; ROPE: TYPE = Rope.ROPE; ReturnCodesNames: PUBLIC ARRAY JoinApp.ReturnCodes OF ROPE _ [ "iluSuccess", "iluECantExportService", "ENotAuthorized" ]; GetReturnCodes: PUBLIC PROC[h: Handle] RETURNS [res: JoinApp.ReturnCodes] = { res _ VAL[SunRPC.GetInt32[h]]; }; PutReturnCodes: PUBLIC PROC[h: Handle, in: JoinApp.ReturnCodes] = { SunRPC.PutInt32[h, ORD[in]]; }; GetJoinApplicationargs: PUBLIC PROC[h: Handle] RETURNS [res: JoinApp.JoinApplicationargs] = { res.in _ UTGetPut.GetObjectDescription[h]; }; PutJoinApplicationargs: PUBLIC PROC[h: Handle, in: JoinApp.JoinApplicationargs] = { UTGetPut.PutObjectDescription[h, in.in]; }; GetJoinApplicationreturn: PUBLIC PROC[h: Handle] RETURNS [res: JoinApp.JoinApplicationreturn] = { tag: JoinApp.ReturnCodes; tag _ GetReturnCodes[h]; SELECT tag FROM iluSuccess => { v: REF iluSuccess JoinApp.JoinApplicationreturnObject _ NEW[iluSuccess JoinApp.JoinApplicationreturnObject]; v.returnValue _ UTGetPut.GetObjectDescription[h]; res _ v; }; ENotAuthorized => { v: REF ENotAuthorized JoinApp.JoinApplicationreturnObject _ NEW[ENotAuthorized JoinApp.JoinApplicationreturnObject]; res _ v; }; iluECantExportService => { v: REF iluECantExportService JoinApp.JoinApplicationreturnObject _ NEW[iluECantExportService JoinApp.JoinApplicationreturnObject]; res _ v; }; ENDCASE => NULL; }; PutJoinApplicationreturn: PUBLIC PROC[h: Handle, in: JoinApp.JoinApplicationreturn] = { PutReturnCodes[h, in.returnCode]; SELECT in.returnCode FROM iluSuccess => { v: REF iluSuccess JoinApp.JoinApplicationreturnObject _ NARROW[in]; UTGetPut.PutObjectDescription[h, v.returnValue]; }; ENotAuthorized => { v: REF ENotAuthorized JoinApp.JoinApplicationreturnObject _ NARROW[in]; }; iluECantExportService => { v: REF iluECantExportService JoinApp.JoinApplicationreturnObject _ NARROW[in]; }; ENDCASE => NULL; }; END.