gid_service.pb.go 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // source: gid_service.proto
  3. package gidSrv // import "."
  4. import proto "github.com/golang/protobuf/proto"
  5. import fmt "fmt"
  6. import math "math"
  7. import (
  8. context "golang.org/x/net/context"
  9. grpc "google.golang.org/grpc"
  10. )
  11. // Reference imports to suppress errors if they are not otherwise used.
  12. var _ = proto.Marshal
  13. var _ = fmt.Errorf
  14. var _ = math.Inf
  15. // This is a compile-time assertion to ensure that this generated file
  16. // is compatible with the proto package it is being compiled against.
  17. // A compilation error at this line likely means your copy of the
  18. // proto package needs to be updated.
  19. const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
  20. type ReqId struct {
  21. BizTag string `protobuf:"bytes,1,opt,name=BizTag,proto3" json:"BizTag,omitempty"`
  22. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  23. XXX_unrecognized []byte `json:"-"`
  24. XXX_sizecache int32 `json:"-"`
  25. }
  26. func (m *ReqId) Reset() { *m = ReqId{} }
  27. func (m *ReqId) String() string { return proto.CompactTextString(m) }
  28. func (*ReqId) ProtoMessage() {}
  29. func (*ReqId) Descriptor() ([]byte, []int) {
  30. return fileDescriptor_gid_service_4d8b77d65df61d37, []int{0}
  31. }
  32. func (m *ReqId) XXX_Unmarshal(b []byte) error {
  33. return xxx_messageInfo_ReqId.Unmarshal(m, b)
  34. }
  35. func (m *ReqId) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  36. return xxx_messageInfo_ReqId.Marshal(b, m, deterministic)
  37. }
  38. func (dst *ReqId) XXX_Merge(src proto.Message) {
  39. xxx_messageInfo_ReqId.Merge(dst, src)
  40. }
  41. func (m *ReqId) XXX_Size() int {
  42. return xxx_messageInfo_ReqId.Size(m)
  43. }
  44. func (m *ReqId) XXX_DiscardUnknown() {
  45. xxx_messageInfo_ReqId.DiscardUnknown(m)
  46. }
  47. var xxx_messageInfo_ReqId proto.InternalMessageInfo
  48. func (m *ReqId) GetBizTag() string {
  49. if m != nil {
  50. return m.BizTag
  51. }
  52. return ""
  53. }
  54. type ResId struct {
  55. Id int64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
  56. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  57. XXX_unrecognized []byte `json:"-"`
  58. XXX_sizecache int32 `json:"-"`
  59. }
  60. func (m *ResId) Reset() { *m = ResId{} }
  61. func (m *ResId) String() string { return proto.CompactTextString(m) }
  62. func (*ResId) ProtoMessage() {}
  63. func (*ResId) Descriptor() ([]byte, []int) {
  64. return fileDescriptor_gid_service_4d8b77d65df61d37, []int{1}
  65. }
  66. func (m *ResId) XXX_Unmarshal(b []byte) error {
  67. return xxx_messageInfo_ResId.Unmarshal(m, b)
  68. }
  69. func (m *ResId) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  70. return xxx_messageInfo_ResId.Marshal(b, m, deterministic)
  71. }
  72. func (dst *ResId) XXX_Merge(src proto.Message) {
  73. xxx_messageInfo_ResId.Merge(dst, src)
  74. }
  75. func (m *ResId) XXX_Size() int {
  76. return xxx_messageInfo_ResId.Size(m)
  77. }
  78. func (m *ResId) XXX_DiscardUnknown() {
  79. xxx_messageInfo_ResId.DiscardUnknown(m)
  80. }
  81. var xxx_messageInfo_ResId proto.InternalMessageInfo
  82. func (m *ResId) GetId() int64 {
  83. if m != nil {
  84. return m.Id
  85. }
  86. return 0
  87. }
  88. func init() {
  89. proto.RegisterType((*ReqId)(nil), "gidSrv.ReqId")
  90. proto.RegisterType((*ResId)(nil), "gidSrv.ResId")
  91. }
  92. // Reference imports to suppress errors if they are not otherwise used.
  93. var _ context.Context
  94. var _ grpc.ClientConn
  95. // This is a compile-time assertion to ensure that this generated file
  96. // is compatible with the grpc package it is being compiled against.
  97. const _ = grpc.SupportPackageIsVersion4
  98. // GidClient is the client API for Gid service.
  99. //
  100. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  101. type GidClient interface {
  102. GetId(ctx context.Context, in *ReqId, opts ...grpc.CallOption) (*ResId, error)
  103. }
  104. type gidClient struct {
  105. cc *grpc.ClientConn
  106. }
  107. func NewGidClient(cc *grpc.ClientConn) GidClient {
  108. return &gidClient{cc}
  109. }
  110. func (c *gidClient) GetId(ctx context.Context, in *ReqId, opts ...grpc.CallOption) (*ResId, error) {
  111. out := new(ResId)
  112. err := c.cc.Invoke(ctx, "/gidSrv.Gid/GetId", in, out, opts...)
  113. if err != nil {
  114. return nil, err
  115. }
  116. return out, nil
  117. }
  118. // GidServer is the server API for Gid service.
  119. type GidServer interface {
  120. GetId(context.Context, *ReqId) (*ResId, error)
  121. }
  122. func RegisterGidServer(s *grpc.Server, srv GidServer) {
  123. s.RegisterService(&_Gid_serviceDesc, srv)
  124. }
  125. func _Gid_GetId_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  126. in := new(ReqId)
  127. if err := dec(in); err != nil {
  128. return nil, err
  129. }
  130. if interceptor == nil {
  131. return srv.(GidServer).GetId(ctx, in)
  132. }
  133. info := &grpc.UnaryServerInfo{
  134. Server: srv,
  135. FullMethod: "/gidSrv.Gid/GetId",
  136. }
  137. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  138. return srv.(GidServer).GetId(ctx, req.(*ReqId))
  139. }
  140. return interceptor(ctx, in, info, handler)
  141. }
  142. var _Gid_serviceDesc = grpc.ServiceDesc{
  143. ServiceName: "gidSrv.Gid",
  144. HandlerType: (*GidServer)(nil),
  145. Methods: []grpc.MethodDesc{
  146. {
  147. MethodName: "GetId",
  148. Handler: _Gid_GetId_Handler,
  149. },
  150. },
  151. Streams: []grpc.StreamDesc{},
  152. Metadata: "gid_service.proto",
  153. }
  154. func init() { proto.RegisterFile("gid_service.proto", fileDescriptor_gid_service_4d8b77d65df61d37) }
  155. var fileDescriptor_gid_service_4d8b77d65df61d37 = []byte{
  156. // 145 bytes of a gzipped FileDescriptorProto
  157. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x4c, 0xcf, 0x4c, 0x89,
  158. 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x4b,
  159. 0xcf, 0x4c, 0x09, 0x2e, 0x2a, 0x53, 0x92, 0xe7, 0x62, 0x0d, 0x4a, 0x2d, 0xf4, 0x4c, 0x11, 0x12,
  160. 0xe3, 0x62, 0x73, 0xca, 0xac, 0x0a, 0x49, 0x4c, 0x97, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x0c, 0x82,
  161. 0xf2, 0x94, 0xc4, 0x41, 0x0a, 0x8a, 0x3d, 0x53, 0x84, 0xf8, 0xb8, 0x98, 0x32, 0x53, 0x24, 0x98,
  162. 0x14, 0x18, 0x35, 0x98, 0x83, 0x98, 0x32, 0x53, 0x8c, 0x74, 0xb8, 0x98, 0xdd, 0x33, 0x53, 0x84,
  163. 0x54, 0xb9, 0x58, 0xdd, 0x53, 0x4b, 0x3c, 0x53, 0x84, 0x78, 0xf5, 0x20, 0x46, 0xea, 0x81, 0xcd,
  164. 0x93, 0x42, 0xe2, 0x16, 0x7b, 0xa6, 0x38, 0x71, 0x45, 0x71, 0xe8, 0x59, 0x43, 0x44, 0x92, 0xd8,
  165. 0xc0, 0x4e, 0x30, 0x06, 0x04, 0x00, 0x00, 0xff, 0xff, 0x2f, 0x42, 0x70, 0x6d, 0x97, 0x00, 0x00,
  166. 0x00,
  167. }