system_service.pb.go 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // source: system_service.proto
  3. // package声明符,用来防止不同的消息类型有命名冲突
  4. package pb
  5. import (
  6. context "context"
  7. fmt "fmt"
  8. proto "github.com/golang/protobuf/proto"
  9. grpc "google.golang.org/grpc"
  10. codes "google.golang.org/grpc/codes"
  11. status "google.golang.org/grpc/status"
  12. math "math"
  13. v1 "property-household-gateway/pb/v1"
  14. )
  15. // Reference imports to suppress errors if they are not otherwise used.
  16. var _ = proto.Marshal
  17. var _ = fmt.Errorf
  18. var _ = math.Inf
  19. // This is a compile-time assertion to ensure that this generated file
  20. // is compatible with the proto package it is being compiled against.
  21. // A compilation error at this line likely means your copy of the
  22. // proto package needs to be updated.
  23. const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
  24. func init() {
  25. proto.RegisterFile("system_service.proto", fileDescriptor_5d35c01297e407e4)
  26. }
  27. var fileDescriptor_5d35c01297e407e4 = []byte{
  28. // 192 bytes of a gzipped FileDescriptorProto
  29. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x29, 0xae, 0x2c, 0x2e,
  30. 0x49, 0xcd, 0x8d, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9,
  31. 0x17, 0xe2, 0x2a, 0x48, 0xd2, 0x83, 0x8a, 0x48, 0xf1, 0x97, 0x19, 0xea, 0x43, 0x14, 0x41, 0x24,
  32. 0x8d, 0xce, 0x31, 0x72, 0xb1, 0x05, 0x83, 0x05, 0x84, 0x9c, 0xb9, 0xb8, 0xdd, 0x13, 0x8b, 0x52,
  33. 0x52, 0xf3, 0x3c, 0xf3, 0xd2, 0xf2, 0x8b, 0x85, 0x24, 0xf5, 0x0a, 0x92, 0xe2, 0xcb, 0x0c, 0xf5,
  34. 0x90, 0xc4, 0x82, 0x52, 0x0b, 0x4b, 0x53, 0x8b, 0x4b, 0xa4, 0xc4, 0xb1, 0x49, 0x15, 0xe4, 0x54,
  35. 0x2a, 0x31, 0x08, 0x39, 0x70, 0x71, 0x41, 0x44, 0x7d, 0x32, 0x8b, 0x4b, 0x84, 0x24, 0x50, 0x14,
  36. 0x82, 0x84, 0x60, 0x46, 0x88, 0x61, 0x91, 0x81, 0x98, 0x60, 0xcb, 0xc5, 0x09, 0x35, 0x37, 0xa5,
  37. 0x58, 0x08, 0xcd, 0xa6, 0x14, 0xb8, 0x13, 0x44, 0x31, 0x25, 0xc0, 0xda, 0x9d, 0xe4, 0xa3, 0x64,
  38. 0x0b, 0x8a, 0xf2, 0x0b, 0x52, 0x8b, 0x4a, 0x2a, 0x75, 0x33, 0xf2, 0x4b, 0x8b, 0x53, 0x33, 0xf2,
  39. 0x73, 0x52, 0x74, 0xd3, 0x13, 0x4b, 0x52, 0xcb, 0x13, 0x2b, 0xf5, 0x0b, 0x92, 0x92, 0xd8, 0xc0,
  40. 0x1e, 0x37, 0x06, 0x04, 0x00, 0x00, 0xff, 0xff, 0x65, 0x7c, 0x02, 0x13, 0x2d, 0x01, 0x00, 0x00,
  41. }
  42. // Reference imports to suppress errors if they are not otherwise used.
  43. var _ context.Context
  44. var _ grpc.ClientConnInterface
  45. // This is a compile-time assertion to ensure that this generated file
  46. // is compatible with the grpc package it is being compiled against.
  47. const _ = grpc.SupportPackageIsVersion6
  48. // SystemClient is the client API for System service.
  49. //
  50. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  51. type SystemClient interface {
  52. GardenInfos(ctx context.Context, in *v1.GardenInfosRequest, opts ...grpc.CallOption) (*v1.GardenInfosReply, error)
  53. GardenList(ctx context.Context, in *v1.GardenListRequest, opts ...grpc.CallOption) (*v1.GardenListReply, error)
  54. GardenIds(ctx context.Context, in *v1.GardenIdsRequest, opts ...grpc.CallOption) (*v1.GardenIdsReply, error)
  55. }
  56. type systemClient struct {
  57. cc grpc.ClientConnInterface
  58. }
  59. func NewSystemClient(cc grpc.ClientConnInterface) SystemClient {
  60. return &systemClient{cc}
  61. }
  62. func (c *systemClient) GardenInfos(ctx context.Context, in *v1.GardenInfosRequest, opts ...grpc.CallOption) (*v1.GardenInfosReply, error) {
  63. out := new(v1.GardenInfosReply)
  64. err := c.cc.Invoke(ctx, "/pb.service.System/GardenInfos", in, out, opts...)
  65. if err != nil {
  66. return nil, err
  67. }
  68. return out, nil
  69. }
  70. func (c *systemClient) GardenList(ctx context.Context, in *v1.GardenListRequest, opts ...grpc.CallOption) (*v1.GardenListReply, error) {
  71. out := new(v1.GardenListReply)
  72. err := c.cc.Invoke(ctx, "/pb.service.System/GardenList", in, out, opts...)
  73. if err != nil {
  74. return nil, err
  75. }
  76. return out, nil
  77. }
  78. func (c *systemClient) GardenIds(ctx context.Context, in *v1.GardenIdsRequest, opts ...grpc.CallOption) (*v1.GardenIdsReply, error) {
  79. out := new(v1.GardenIdsReply)
  80. err := c.cc.Invoke(ctx, "/pb.service.System/GardenIds", in, out, opts...)
  81. if err != nil {
  82. return nil, err
  83. }
  84. return out, nil
  85. }
  86. // SystemServer is the server API for System service.
  87. type SystemServer interface {
  88. GardenInfos(context.Context, *v1.GardenInfosRequest) (*v1.GardenInfosReply, error)
  89. GardenList(context.Context, *v1.GardenListRequest) (*v1.GardenListReply, error)
  90. GardenIds(context.Context, *v1.GardenIdsRequest) (*v1.GardenIdsReply, error)
  91. }
  92. // UnimplementedSystemServer can be embedded to have forward compatible implementations.
  93. type UnimplementedSystemServer struct {
  94. }
  95. func (*UnimplementedSystemServer) GardenInfos(ctx context.Context, req *v1.GardenInfosRequest) (*v1.GardenInfosReply, error) {
  96. return nil, status.Errorf(codes.Unimplemented, "method GardenInfos not implemented")
  97. }
  98. func (*UnimplementedSystemServer) GardenList(ctx context.Context, req *v1.GardenListRequest) (*v1.GardenListReply, error) {
  99. return nil, status.Errorf(codes.Unimplemented, "method GardenList not implemented")
  100. }
  101. func (*UnimplementedSystemServer) GardenIds(ctx context.Context, req *v1.GardenIdsRequest) (*v1.GardenIdsReply, error) {
  102. return nil, status.Errorf(codes.Unimplemented, "method GardenIds not implemented")
  103. }
  104. func RegisterSystemServer(s *grpc.Server, srv SystemServer) {
  105. s.RegisterService(&_System_serviceDesc, srv)
  106. }
  107. func _System_GardenInfos_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  108. in := new(v1.GardenInfosRequest)
  109. if err := dec(in); err != nil {
  110. return nil, err
  111. }
  112. if interceptor == nil {
  113. return srv.(SystemServer).GardenInfos(ctx, in)
  114. }
  115. info := &grpc.UnaryServerInfo{
  116. Server: srv,
  117. FullMethod: "/pb.service.System/GardenInfos",
  118. }
  119. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  120. return srv.(SystemServer).GardenInfos(ctx, req.(*v1.GardenInfosRequest))
  121. }
  122. return interceptor(ctx, in, info, handler)
  123. }
  124. func _System_GardenList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  125. in := new(v1.GardenListRequest)
  126. if err := dec(in); err != nil {
  127. return nil, err
  128. }
  129. if interceptor == nil {
  130. return srv.(SystemServer).GardenList(ctx, in)
  131. }
  132. info := &grpc.UnaryServerInfo{
  133. Server: srv,
  134. FullMethod: "/pb.service.System/GardenList",
  135. }
  136. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  137. return srv.(SystemServer).GardenList(ctx, req.(*v1.GardenListRequest))
  138. }
  139. return interceptor(ctx, in, info, handler)
  140. }
  141. func _System_GardenIds_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  142. in := new(v1.GardenIdsRequest)
  143. if err := dec(in); err != nil {
  144. return nil, err
  145. }
  146. if interceptor == nil {
  147. return srv.(SystemServer).GardenIds(ctx, in)
  148. }
  149. info := &grpc.UnaryServerInfo{
  150. Server: srv,
  151. FullMethod: "/pb.service.System/GardenIds",
  152. }
  153. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  154. return srv.(SystemServer).GardenIds(ctx, req.(*v1.GardenIdsRequest))
  155. }
  156. return interceptor(ctx, in, info, handler)
  157. }
  158. var _System_serviceDesc = grpc.ServiceDesc{
  159. ServiceName: "pb.service.System",
  160. HandlerType: (*SystemServer)(nil),
  161. Methods: []grpc.MethodDesc{
  162. {
  163. MethodName: "GardenInfos",
  164. Handler: _System_GardenInfos_Handler,
  165. },
  166. {
  167. MethodName: "GardenList",
  168. Handler: _System_GardenList_Handler,
  169. },
  170. {
  171. MethodName: "GardenIds",
  172. Handler: _System_GardenIds_Handler,
  173. },
  174. },
  175. Streams: []grpc.StreamDesc{},
  176. Metadata: "system_service.proto",
  177. }