### Generated by rprotoc. DO NOT EDIT!### <proto file: rpc.proto># // Copyright (c) 2009 Shardul Deo# //# // Permission is hereby granted, free of charge, to any person obtaining a copy# // of this software and associated documentation files (the "Software"), to deal# // in the Software without restriction, including without limitation the rights# // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell# // copies of the Software, and to permit persons to whom the Software is# // furnished to do so, subject to the following conditions:# //# // The above copyright notice and this permission notice shall be included in# // all copies or substantial portions of the Software.# //# // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR# // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,# // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE# // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER# // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,# // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN# // THE SOFTWARE.# # // Author: Shardul Deo# //# // Protobufs needed for socket rpcs.# # package protobuf.socketrpc;# # message Request {# # // RPC service full name# required string service_name = 1;# # // RPC method name# required string method_name = 2;# # // RPC request proto# required bytes request_proto = 3;# }# # message Response {# # // RPC response proto# optional bytes response_proto = 1;# # // Error, if any# optional string error = 2;# # // Was callback invoked# optional bool callback = 3 [default = false];# # // Error Reason# optional ErrorReason error_reason = 4;# }# # // Possible error reasons# // The server-side errors are returned in the response from the server.# // The client-side errors are returned by the client-side code when it doesn't # // have a response from the server.# enum ErrorReason {# # // Server-side errors# BAD_REQUEST_DATA = 0; // Server received bad request data# BAD_REQUEST_PROTO = 1; // Server received bad request proto# SERVICE_NOT_FOUND = 2; // Service not found on server# METHOD_NOT_FOUND = 3; // Method not found on server# RPC_ERROR = 4; // Rpc threw exception on server# RPC_FAILED = 5; // Rpc failed on server# # // Client-side errors (these are returned by the client-side code)# INVALID_REQUEST_PROTO = 6; // Rpc was called with invalid request proto# BAD_RESPONSE_PROTO = 7; // Server returned a bad response proto# UNKNOWN_HOST = 8; // Could not find supplied host# IO_ERROR = 9; // I/O error while communicating with server# }require'protobuf/message'moduleProtobufmoduleSocketrpc### Enum Classes#classErrorReason<::Protobuf::Enum;end### Message Classes#classRequest<::Protobuf::Message;endclassResponse<::Protobuf::Message;end### Enum Values#::Protobuf::Socketrpc::ErrorReason.define:BAD_REQUEST_DATA,0::Protobuf::Socketrpc::ErrorReason.define:BAD_REQUEST_PROTO,1::Protobuf::Socketrpc::ErrorReason.define:SERVICE_NOT_FOUND,2::Protobuf::Socketrpc::ErrorReason.define:METHOD_NOT_FOUND,3::Protobuf::Socketrpc::ErrorReason.define:RPC_ERROR,4::Protobuf::Socketrpc::ErrorReason.define:RPC_FAILED,5::Protobuf::Socketrpc::ErrorReason.define:INVALID_REQUEST_PROTO,6::Protobuf::Socketrpc::ErrorReason.define:BAD_RESPONSE_PROTO,7::Protobuf::Socketrpc::ErrorReason.define:UNKNOWN_HOST,8::Protobuf::Socketrpc::ErrorReason.define:IO_ERROR,9### Message Fields#::Protobuf::Socketrpc::Request.required(::Protobuf::Field::StringField,:service_name,1)::Protobuf::Socketrpc::Request.required(::Protobuf::Field::StringField,:method_name,2)::Protobuf::Socketrpc::Request.required(::Protobuf::Field::BytesField,:request_proto,3)::Protobuf::Socketrpc::Response.optional(::Protobuf::Field::BytesField,:response_proto,1)::Protobuf::Socketrpc::Response.optional(::Protobuf::Field::StringField,:error,2)::Protobuf::Socketrpc::Response.optional(::Protobuf::Field::BoolField,:callback,3,:default=>false)::Protobuf::Socketrpc::Response.optional(::Protobuf::Socketrpc::ErrorReason,:error_reason,4)endend