d4233555e7dc9e0fb8d470746d70e7112a2b51c4.svn-base 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // source: string.proto
  3. package pb
  4. import (
  5. context "context"
  6. fmt "fmt"
  7. proto "github.com/golang/protobuf/proto"
  8. grpc "google.golang.org/grpc"
  9. codes "google.golang.org/grpc/codes"
  10. status "google.golang.org/grpc/status"
  11. math "math"
  12. )
  13. // Reference imports to suppress errors if they are not otherwise used.
  14. var _ = proto.Marshal
  15. var _ = fmt.Errorf
  16. var _ = math.Inf
  17. // This is a compile-time assertion to ensure that this generated file
  18. // is compatible with the proto package it is being compiled against.
  19. // A compilation error at this line likely means your copy of the
  20. // proto package needs to be updated.
  21. const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
  22. type StringRequest struct {
  23. RequestType string `protobuf:"bytes,1,opt,name=request_type,json=requestType,proto3" json:"request_type,omitempty"`
  24. A string `protobuf:"bytes,2,opt,name=a,proto3" json:"a,omitempty"`
  25. B string `protobuf:"bytes,3,opt,name=b,proto3" json:"b,omitempty"`
  26. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  27. XXX_unrecognized []byte `json:"-"`
  28. XXX_sizecache int32 `json:"-"`
  29. }
  30. func (m *StringRequest) Reset() { *m = StringRequest{} }
  31. func (m *StringRequest) String() string { return proto.CompactTextString(m) }
  32. func (*StringRequest) ProtoMessage() {}
  33. func (*StringRequest) Descriptor() ([]byte, []int) {
  34. return fileDescriptor_38ecded40dd872b6, []int{0}
  35. }
  36. func (m *StringRequest) XXX_Unmarshal(b []byte) error {
  37. return xxx_messageInfo_StringRequest.Unmarshal(m, b)
  38. }
  39. func (m *StringRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  40. return xxx_messageInfo_StringRequest.Marshal(b, m, deterministic)
  41. }
  42. func (m *StringRequest) XXX_Merge(src proto.Message) {
  43. xxx_messageInfo_StringRequest.Merge(m, src)
  44. }
  45. func (m *StringRequest) XXX_Size() int {
  46. return xxx_messageInfo_StringRequest.Size(m)
  47. }
  48. func (m *StringRequest) XXX_DiscardUnknown() {
  49. xxx_messageInfo_StringRequest.DiscardUnknown(m)
  50. }
  51. var xxx_messageInfo_StringRequest proto.InternalMessageInfo
  52. func (m *StringRequest) GetRequestType() string {
  53. if m != nil {
  54. return m.RequestType
  55. }
  56. return ""
  57. }
  58. func (m *StringRequest) GetA() string {
  59. if m != nil {
  60. return m.A
  61. }
  62. return ""
  63. }
  64. func (m *StringRequest) GetB() string {
  65. if m != nil {
  66. return m.B
  67. }
  68. return ""
  69. }
  70. type StringResponse struct {
  71. Result string `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
  72. Err string `protobuf:"bytes,2,opt,name=err,proto3" json:"err,omitempty"`
  73. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  74. XXX_unrecognized []byte `json:"-"`
  75. XXX_sizecache int32 `json:"-"`
  76. }
  77. func (m *StringResponse) Reset() { *m = StringResponse{} }
  78. func (m *StringResponse) String() string { return proto.CompactTextString(m) }
  79. func (*StringResponse) ProtoMessage() {}
  80. func (*StringResponse) Descriptor() ([]byte, []int) {
  81. return fileDescriptor_38ecded40dd872b6, []int{1}
  82. }
  83. func (m *StringResponse) XXX_Unmarshal(b []byte) error {
  84. return xxx_messageInfo_StringResponse.Unmarshal(m, b)
  85. }
  86. func (m *StringResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  87. return xxx_messageInfo_StringResponse.Marshal(b, m, deterministic)
  88. }
  89. func (m *StringResponse) XXX_Merge(src proto.Message) {
  90. xxx_messageInfo_StringResponse.Merge(m, src)
  91. }
  92. func (m *StringResponse) XXX_Size() int {
  93. return xxx_messageInfo_StringResponse.Size(m)
  94. }
  95. func (m *StringResponse) XXX_DiscardUnknown() {
  96. xxx_messageInfo_StringResponse.DiscardUnknown(m)
  97. }
  98. var xxx_messageInfo_StringResponse proto.InternalMessageInfo
  99. func (m *StringResponse) GetResult() string {
  100. if m != nil {
  101. return m.Result
  102. }
  103. return ""
  104. }
  105. func (m *StringResponse) GetErr() string {
  106. if m != nil {
  107. return m.Err
  108. }
  109. return ""
  110. }
  111. func init() {
  112. proto.RegisterType((*StringRequest)(nil), "pb.StringRequest")
  113. proto.RegisterType((*StringResponse)(nil), "pb.StringResponse")
  114. }
  115. func init() { proto.RegisterFile("string.proto", fileDescriptor_38ecded40dd872b6) }
  116. var fileDescriptor_38ecded40dd872b6 = []byte{
  117. // 178 bytes of a gzipped FileDescriptorProto
  118. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x29, 0x2e, 0x29, 0xca,
  119. 0xcc, 0x4b, 0xd7, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x2a, 0x48, 0x52, 0xf2, 0xe3, 0xe2,
  120. 0x0d, 0x06, 0x8b, 0x05, 0xa5, 0x16, 0x96, 0xa6, 0x16, 0x97, 0x08, 0x29, 0x72, 0xf1, 0x14, 0x41,
  121. 0x98, 0xf1, 0x25, 0x95, 0x05, 0xa9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0xdc, 0x50, 0xb1,
  122. 0x90, 0xca, 0x82, 0x54, 0x21, 0x1e, 0x2e, 0xc6, 0x44, 0x09, 0x26, 0xb0, 0x38, 0x63, 0x22, 0x88,
  123. 0x97, 0x24, 0xc1, 0x0c, 0xe1, 0x25, 0x29, 0x59, 0x71, 0xf1, 0xc1, 0xcc, 0x2b, 0x2e, 0xc8, 0xcf,
  124. 0x2b, 0x4e, 0x15, 0x12, 0xe3, 0x62, 0x2b, 0x4a, 0x2d, 0x2e, 0xcd, 0x29, 0x81, 0x1a, 0x05, 0xe5,
  125. 0x09, 0x09, 0x70, 0x31, 0xa7, 0x16, 0x15, 0x41, 0xcd, 0x01, 0x31, 0x8d, 0x1c, 0x60, 0x6e, 0x09,
  126. 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x15, 0xd2, 0xe7, 0x62, 0x71, 0xc9, 0x4c, 0x4b, 0x13, 0x12,
  127. 0xd4, 0x2b, 0x48, 0xd2, 0x43, 0x71, 0xa6, 0x94, 0x10, 0xb2, 0x10, 0xc4, 0x26, 0x25, 0x86, 0x24,
  128. 0x36, 0xb0, 0xc7, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0x19, 0xa1, 0xe9, 0xf2, 0xe8, 0x00,
  129. 0x00, 0x00,
  130. }
  131. // Reference imports to suppress errors if they are not otherwise used.
  132. var _ context.Context
  133. var _ grpc.ClientConn
  134. // This is a compile-time assertion to ensure that this generated file
  135. // is compatible with the grpc package it is being compiled against.
  136. const _ = grpc.SupportPackageIsVersion4
  137. // StringServiceClient is the client API for StringService service.
  138. //
  139. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  140. type StringServiceClient interface {
  141. Diff(ctx context.Context, in *StringRequest, opts ...grpc.CallOption) (*StringResponse, error)
  142. }
  143. type stringServiceClient struct {
  144. cc *grpc.ClientConn
  145. }
  146. func NewStringServiceClient(cc *grpc.ClientConn) StringServiceClient {
  147. return &stringServiceClient{cc}
  148. }
  149. func (c *stringServiceClient) Diff(ctx context.Context, in *StringRequest, opts ...grpc.CallOption) (*StringResponse, error) {
  150. out := new(StringResponse)
  151. err := c.cc.Invoke(ctx, "/pb.StringService/Diff", in, out, opts...)
  152. if err != nil {
  153. return nil, err
  154. }
  155. return out, nil
  156. }
  157. // StringServiceServer is the server API for StringService service.
  158. type StringServiceServer interface {
  159. Diff(context.Context, *StringRequest) (*StringResponse, error)
  160. }
  161. // UnimplementedStringServiceServer can be embedded to have forward compatible implementations.
  162. type UnimplementedStringServiceServer struct {
  163. }
  164. func (*UnimplementedStringServiceServer) Diff(ctx context.Context, req *StringRequest) (*StringResponse, error) {
  165. return nil, status.Errorf(codes.Unimplemented, "method Diff not implemented")
  166. }
  167. func RegisterStringServiceServer(s *grpc.Server, srv StringServiceServer) {
  168. s.RegisterService(&_StringService_serviceDesc, srv)
  169. }
  170. func _StringService_Diff_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  171. in := new(StringRequest)
  172. if err := dec(in); err != nil {
  173. return nil, err
  174. }
  175. if interceptor == nil {
  176. return srv.(StringServiceServer).Diff(ctx, in)
  177. }
  178. info := &grpc.UnaryServerInfo{
  179. Server: srv,
  180. FullMethod: "/pb.StringService/Diff",
  181. }
  182. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  183. return srv.(StringServiceServer).Diff(ctx, req.(*StringRequest))
  184. }
  185. return interceptor(ctx, in, info, handler)
  186. }
  187. var _StringService_serviceDesc = grpc.ServiceDesc{
  188. ServiceName: "pb.StringService",
  189. HandlerType: (*StringServiceServer)(nil),
  190. Methods: []grpc.MethodDesc{
  191. {
  192. MethodName: "Diff",
  193. Handler: _StringService_Diff_Handler,
  194. },
  195. },
  196. Streams: []grpc.StreamDesc{},
  197. Metadata: "string.proto",
  198. }