system_service.pb.go 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  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-device/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. // 136 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, 0x7c, 0xb9, 0xd8, 0x82, 0xc1, 0x7c, 0x21, 0x67, 0x2e, 0x6e, 0xf7, 0xc4, 0xa2, 0x94, 0xd4,
  33. 0x3c, 0xcf, 0xbc, 0xb4, 0xfc, 0x62, 0x21, 0x49, 0xbd, 0x82, 0xa4, 0xf8, 0x32, 0x43, 0x3d, 0x24,
  34. 0xb1, 0xa0, 0xd4, 0xc2, 0xd2, 0xd4, 0xe2, 0x12, 0x29, 0x71, 0x6c, 0x52, 0x05, 0x39, 0x95, 0x4a,
  35. 0x0c, 0x4e, 0x22, 0x51, 0x42, 0x05, 0x45, 0xf9, 0x05, 0xa9, 0x45, 0x25, 0x95, 0xba, 0x29, 0xa9,
  36. 0x20, 0x2b, 0xf5, 0x0b, 0x92, 0x92, 0xd8, 0xc0, 0x76, 0x19, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff,
  37. 0xb3, 0xf0, 0x52, 0xf9, 0xa0, 0x00, 0x00, 0x00,
  38. }
  39. // Reference imports to suppress errors if they are not otherwise used.
  40. var _ context.Context
  41. var _ grpc.ClientConnInterface
  42. // This is a compile-time assertion to ensure that this generated file
  43. // is compatible with the grpc package it is being compiled against.
  44. const _ = grpc.SupportPackageIsVersion6
  45. // SystemClient is the client API for System service.
  46. //
  47. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  48. type SystemClient interface {
  49. GardenInfos(ctx context.Context, in *v1.GardenInfosRequest, opts ...grpc.CallOption) (*v1.GardenInfosReply, error)
  50. }
  51. type systemClient struct {
  52. cc grpc.ClientConnInterface
  53. }
  54. func NewSystemClient(cc grpc.ClientConnInterface) SystemClient {
  55. return &systemClient{cc}
  56. }
  57. func (c *systemClient) GardenInfos(ctx context.Context, in *v1.GardenInfosRequest, opts ...grpc.CallOption) (*v1.GardenInfosReply, error) {
  58. out := new(v1.GardenInfosReply)
  59. err := c.cc.Invoke(ctx, "/pb.service.System/GardenInfos", in, out, opts...)
  60. if err != nil {
  61. return nil, err
  62. }
  63. return out, nil
  64. }
  65. // SystemServer is the server API for System service.
  66. type SystemServer interface {
  67. GardenInfos(context.Context, *v1.GardenInfosRequest) (*v1.GardenInfosReply, error)
  68. }
  69. // UnimplementedSystemServer can be embedded to have forward compatible implementations.
  70. type UnimplementedSystemServer struct {
  71. }
  72. func (*UnimplementedSystemServer) GardenInfos(ctx context.Context, req *v1.GardenInfosRequest) (*v1.GardenInfosReply, error) {
  73. return nil, status.Errorf(codes.Unimplemented, "method GardenInfos not implemented")
  74. }
  75. func RegisterSystemServer(s *grpc.Server, srv SystemServer) {
  76. s.RegisterService(&_System_serviceDesc, srv)
  77. }
  78. func _System_GardenInfos_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  79. in := new(v1.GardenInfosRequest)
  80. if err := dec(in); err != nil {
  81. return nil, err
  82. }
  83. if interceptor == nil {
  84. return srv.(SystemServer).GardenInfos(ctx, in)
  85. }
  86. info := &grpc.UnaryServerInfo{
  87. Server: srv,
  88. FullMethod: "/pb.service.System/GardenInfos",
  89. }
  90. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  91. return srv.(SystemServer).GardenInfos(ctx, req.(*v1.GardenInfosRequest))
  92. }
  93. return interceptor(ctx, in, info, handler)
  94. }
  95. var _System_serviceDesc = grpc.ServiceDesc{
  96. ServiceName: "pb.service.System",
  97. HandlerType: (*SystemServer)(nil),
  98. Methods: []grpc.MethodDesc{
  99. {
  100. MethodName: "GardenInfos",
  101. Handler: _System_GardenInfos_Handler,
  102. },
  103. },
  104. Streams: []grpc.StreamDesc{},
  105. Metadata: "system_service.proto",
  106. }