public pb::IMessage GetRequestPrototype(pbd::MethodDescriptor method) { if (method.Service != Descriptor) { throw new global::System.ArgumentException( "Service.GetRequestPrototype() given method descriptor for wrong service type."); } switch (method.Index) { case 0: return(global::Google.ProtocolBuffers.TestProtos.CustomOptionFooRequest.DefaultInstance); default: throw new global::System.InvalidOperationException("Can't get here."); } }
public pb::IMessage GetResponsePrototype(pbd::MethodDescriptor method) { if (method.Service != Descriptor) { throw new global::System.ArgumentException( "Service.GetResponsePrototype() given method descriptor for wrong service type."); } switch (method.Index) { case 0: return(global::bnet.protocol.channel.FindChannelResponse.DefaultInstance); case 1: return(global::bnet.protocol.channel.CreateChannelResponse.DefaultInstance); case 2: return(global::bnet.protocol.channel.JoinChannelResponse.DefaultInstance); default: throw new global::System.InvalidOperationException("Can't get here."); } }
public void CallMethod( pbd::MethodDescriptor method, pb::IRpcController controller, pb::IMessage request, global::System.Action <pb::IMessage> done) { if (method.Service != Descriptor) { throw new global::System.ArgumentException( "Service.CallMethod() given method descriptor for wrong service type."); } switch (method.Index) { case 0: this.GetContentHandle(controller, (global::bnet.protocol.resources.ContentHandleRequest)request, pb::RpcUtil.SpecializeCallback <global::bnet.protocol.ContentHandle>( done)); return; default: throw new global::System.InvalidOperationException("Can't get here."); } }
public void CallMethod( pbd::MethodDescriptor method, pb::IRpcController controller, pb::IMessage request, global::System.Action <pb::IMessage> done) { if (method.Service != Descriptor) { throw new global::System.ArgumentException( "Service.CallMethod() given method descriptor for wrong service type."); } switch (method.Index) { case 0: this.Foo(controller, (global::Google.ProtocolBuffers.TestProtos.CustomOptionFooRequest)request, pb::RpcUtil.SpecializeCallback <global::Google.ProtocolBuffers.TestProtos.CustomOptionFooResponse>( done)); return; default: throw new global::System.InvalidOperationException("Can't get here."); } }