-- Copyright (C) 1987 by Xerox Corporation.  All rights reserved.
-- Stub file  was translated on April 4, 1987 3:20:46 pm PST by Lupine of January 22, 1987 5:37:32 pm PST
-- Source interface VoiceRopeServer came from file VoiceRopeServer.bcd, which was created on April 4, 1987 3:20:37 pm PST with version stamp 111#303#12647064743 from source of August 25, 1986 4:34:23 pm PDT.

-- The RPC stub modules for VoiceRopeServer are:
--   VoiceRopeServerRpcControl.mesa;
--   VoiceRopeServerRpcClientImpl.mesa;
--   VoiceRopeServerRpcBinderImpl.mesa;
--   VoiceRopeServerRpcServerImpl.mesa.

-- The parameters for this translation are:
--   Target language = Cedar
--   Default parameter passing = VALUE
--   Deallocate server heap arguments = TRUE
--   Inline RpcServerImpl dispatcher stubs = TRUE
--   Declare signals = TRUE
--   Warn about short POINTER ("MDS") allocations = TRUE
--   Maximum number of dynamic heap NEWs = 50, MDS NEWs = 50
--   Acceptable parameter protocols = VersionRange[1..1].


DIRECTORY
  RefID,
  Rope,
  Thrush,
  VoiceRopeServer,
  RPC USING [defaultInterfaceName, EncryptionKey, InterfaceName, Principal,
      standardZones, VersionRange, Zones],
  RPCLupine USING [ImportHandle, noHost, RPCHost];


VoiceRopeServerRpcControl: DEFINITIONS
  SHARES  VoiceRopeServer
  = BEGIN OPEN VoiceRopeServer, RpcPublic: RPC, RpcPrivate: RPCLupine;


-- Public RPC types and constants.

  InterfaceName: TYPE = RpcPublic.InterfaceName;
  VersionRange: TYPE = RpcPublic.VersionRange;
  Principal: TYPE = RpcPublic.Principal;
  EncryptionKey: TYPE = RpcPublic.EncryptionKey;
  Zones: TYPE = RpcPublic.Zones;
  
  defaultInterfaceName: InterfaceName = RpcPublic.defaultInterfaceName;
  standardZones: Zones = RpcPublic.standardZones;


-- Standard remote binding routines.

  ImportInterface: SAFE PROCEDURE [
        interfaceName: InterfaceName ← defaultInterfaceName,
        parameterStorage: Zones ← standardZones,
        hostHint: RpcPrivate.RPCHost←RpcPrivate.noHost];

  UnimportInterface: PROCEDURE;

  ExportInterface: SAFE PROCEDURE [
        interfaceName: InterfaceName ← defaultInterfaceName,
        user: Principal,
        password: EncryptionKey,
        parameterStorage: Zones ← standardZones ];

  UnexportInterface: SAFE PROCEDURE;


-- Dynamic instantiation and binding.

  ImportNewInterface: SAFE PROCEDURE [
        interfaceName: InterfaceName ← defaultInterfaceName,
        parameterStorage: Zones ← standardZones,
        hostHint: RpcPrivate.RPCHost←RpcPrivate.noHost]
    RETURNS [interfaceRecord: InterfaceRecord];

  -- NewInterfaceRecord is necessary for Cedar clients who want to
  -- manufacture a private interface instance, because
  -- RpcBindingImpl has finalization on type InterfaceRecord.
  NewInterfaceRecord: SAFE PROCEDURE
    RETURNS [interfaceRecord: InterfaceRecord];

  InterfaceRecord: TYPE = REF InterfaceRecordObject;

  InterfaceRecordObject: TYPE = RECORD [
      Record: SAFE PROCEDURE [shhh: Thrush.SHHH, credentials: Thrush.Credentials,
          serviceID: RefID.ID, intID: CARD, queueIt: BOOL] RETURNS [nb:
          Thrush.NB, voiceRope: VoiceRope],
      Play: SAFE PROCEDURE [shhh: Thrush.SHHH, voiceRope: VoiceRope,
          credentials: Thrush.Credentials, serviceID: RefID.ID, intID:
          CARD, queueIt: BOOL] RETURNS [nb: Thrush.NB],
      Stop: SAFE PROCEDURE [shhh: Thrush.SHHH, credentials: Thrush.Credentials,
          serviceID: RefID.ID] RETURNS [nb: Thrush.NB],
      Retain: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope, class:
          InterestClass, refID: Rope.ROPE, other: Rope.ROPE] RETURNS [nb:
          Thrush.NB],
      Forget: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope, class:
          InterestClass, refID: Rope.ROPE] RETURNS [nb: Thrush.NB],
      GetByInterest: SAFE PROCEDURE [shhh: Thrush.SHHH, class: InterestClass,
          refID: Rope.ROPE] RETURNS [nb: Thrush.NB, voiceRope: VoiceRope],
      Cat: SAFE PROCEDURE [shhh: Thrush.SHHH, vr1: VoiceRope, vr2:
          VoiceRope, vr3: VoiceRope, vr4: VoiceRope, vr5: VoiceRope] RETURNS
          [nb: Thrush.NB, new: VoiceRope],
      Substr: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope, start:
          INT, len: INT] RETURNS [nb: Thrush.NB, new: VoiceRope],
      Replace: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope, start:
          INT, len: INT, with: VoiceRope] RETURNS [nb: Thrush.NB, new:
          VoiceRope],
      Length: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope] RETURNS
          [nb: Thrush.NB, len: INT],
      DescribeRope: SAFE PROCEDURE [shhh: Thrush.SHHH, vr: VoiceRope,
          minSilence: INT] RETURNS [nb: Thrush.NB, length: INT, noise:
          IntervalSpecs],
      lupineDetails: PRIVATE REF LupineDetailsObject←NIL];

  LupineDetailsObject: PRIVATE TYPE;

 -- Definitions for the stubs.
 
 LupineProtocolVersion: PUBLIC VersionRange = [first: 1, last: 1];
 
 InterMdsCallsOnly: PUBLIC BOOLEAN = FALSE;

  ProcedureIndex: PRIVATE TYPE = MACHINE DEPENDENT {
      LupineUnusedIndex (0), LupineLastIndex (3),
      Record (4), Play (5), Stop (6), Retain (7), Forget (8), GetByInterest
      (9), Cat (10), Substr (11), Replace (12), Length (13), DescribeRope
      (14)};

  SignalIndex: PRIVATE TYPE = MACHINE DEPENDENT {
      LupineUnusedIndex (0), LupineLastIndex (3)};


END.  -- VoiceRopeServerRpcControl.