DIRECTORY Commander USING [ CommandProc, Register ], CommandTool USING [ NextArgument ], ExplicitExport USING [ ExportExplicitly ], IO, LarkControl USING [ BootLark, GetLark, LarkData ], LarkRemoteControl, LarkRemoteControlRpcControl, LarkRemoteControlRpcServerImpl, Rope USING [ ROPE ], RPC USING [ ExportFailed, matchAllVersions ], RPCPkt USING[Machine], UserProfile USING [ Token ], VoiceUtils USING [ CurrentRName, CurrentPasskey, Problem, ReportFR ] ; LarkRemoteControlServerImpl: CEDAR PROGRAM IMPORTS Commander, CommandTool, ExplicitExport, IO, LarkControl, LarkRemoteControlRpcControl, LarkRemoteControlRpcServerImpl, RPC, UserProfile, VoiceUtils EXPORTS LarkRemoteControl SHARES LarkRemoteControlRpcServerImpl = { OPEN IO; BootLark: PUBLIC PROC[lark: RPCPkt.Machine] RETURNS [outcome: BOOL_TRUE] ={ larkData: LarkControl.LarkData = LarkControl.GetLark[lark]; IF larkData=NIL THEN RETURN[FALSE]; LarkControl.BootLark[larkData]; }; ExptCmd: Commander.CommandProc = { ENABLE RPC.ExportFailed => { VoiceUtils.Problem["Couldn't export LarkRemoteControl.Lark"]; CONTINUE; }; instance: Rope.ROPE _ CommandTool.NextArgument[cmd]; IF instance = NIL THEN instance _ UserProfile.Token[key: "ThrushServerInstance", default: "Morley.Lark"]; LarkRemoteControlRpcControl.ExportInterface [ interfaceName: [ type: "LarkRemoteControl.Lark", instance: instance ], user: VoiceUtils.CurrentRName[], password: VoiceUtils.CurrentPasskey[] ]; ExplicitExport.ExportExplicitly["LarkRemoteControl.Lark", instance, RPC.matchAllVersions, LarkRemoteControlRpcControl.LupineProtocolVersion, LarkRemoteControlRpcServerImpl.ServerDispatcher]; VoiceUtils.ReportFR[remark: "ExportInterface[LarkRemoteControl.Lark, %s]", a1: rope[instance], where: $System]; }; Commander.Register["ExportLarkRemote", ExptCmd, "ExportLarkRemote Strowger.Lark makes the LarkRemoteControl interface available."]; }. žLarkRemoteControlServerImpl.mesa Copyright c 1985 by Xerox Corporation. All rights reserved. Last Edited by: Swinehart, November 25, 1985 1:53:02 pm PST [cmd: Commander.Handle] RETURNS [result: REF ANY _ NIL, msg: ROPE _ NIL] Swinehart, September 9, 1985 10:47:13 am PDT Created -- allows rudimentary control of larks by end-user RPC command. Expect this to grow. changes to: DIRECTORY, LarkRemoteControl ΚF˜šœ ™ Icodešœ Οmœ1™žœ˜J——Jšœžœ!˜4šžœ žœžœ ˜!J˜G—šœ-˜-˜Jšœ˜J˜J˜—J˜ J˜%J˜—JšœDžœw˜ΎJšœo˜oJ˜J˜—J˜ƒJšœ˜J˜—™,™GK™—Kšœ Οr™(—K™J˜—…—V :