log_service.pb.go 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // source: log_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 "smart-supplier-management-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("log_service.proto", fileDescriptor_c40f363b56b74b92)
  26. }
  27. var fileDescriptor_c40f363b56b74b92 = []byte{
  28. // 181 bytes of a gzipped FileDescriptorProto
  29. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x54, 0x8e, 0x31, 0xcb, 0xc2, 0x30,
  30. 0x10, 0x40, 0x3f, 0xbe, 0xa1, 0x42, 0x10, 0xb4, 0x19, 0x1c, 0x3a, 0x8a, 0xb8, 0x35, 0xa5, 0xfa,
  31. 0x0b, 0x74, 0xce, 0x64, 0x37, 0x97, 0x92, 0xda, 0x23, 0x04, 0xd2, 0x5e, 0x9a, 0x5c, 0x2b, 0xfd,
  32. 0xf7, 0xd2, 0x56, 0x41, 0xb7, 0xbb, 0xf7, 0x78, 0xdc, 0xb1, 0xd8, 0xa2, 0x2e, 0x03, 0xf8, 0xc1,
  33. 0x3c, 0x40, 0x38, 0x8f, 0x84, 0xfc, 0xdf, 0x55, 0xc9, 0x6e, 0xc8, 0x33, 0x74, 0xe0, 0x15, 0x19,
  34. 0x6c, 0x4b, 0x8b, 0x7a, 0x71, 0xa7, 0x8e, 0xad, 0x8b, 0x46, 0x79, 0x2a, 0x0c, 0x81, 0x44, 0xcd,
  35. 0x05, 0x8b, 0x24, 0xea, 0x4b, 0x5d, 0xf3, 0x58, 0x0c, 0xb9, 0x58, 0xe6, 0x1b, 0x74, 0x3d, 0x04,
  36. 0x4a, 0x36, 0xdf, 0xc8, 0xd9, 0x71, 0xff, 0xc7, 0x73, 0xb6, 0x92, 0xa8, 0xa5, 0x09, 0xc4, 0xf9,
  37. 0xdb, 0x4e, 0xcb, 0xa7, 0xd8, 0xfe, 0xb0, 0x39, 0xb9, 0x1e, 0xef, 0x87, 0x30, 0x9d, 0x4c, 0x43,
  38. 0xef, 0x9c, 0x35, 0xe0, 0xd3, 0x46, 0xb5, 0x4a, 0x43, 0x03, 0x2d, 0xa5, 0x5a, 0x11, 0x3c, 0xd5,
  39. 0x98, 0xb9, 0xaa, 0x8a, 0xe6, 0x0f, 0xcf, 0xaf, 0x00, 0x00, 0x00, 0xff, 0xff, 0xc7, 0x53, 0x30,
  40. 0xaf, 0xd2, 0x00, 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. // SmartSiteLogClient is the client API for SmartSiteLog 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 SmartSiteLogClient interface {
  52. LogAdd(ctx context.Context, in *v1.LogAddRequest, opts ...grpc.CallOption) (*v1.LogAddReply, error)
  53. LogList(ctx context.Context, in *v1.LogListRequest, opts ...grpc.CallOption) (*v1.LogListReply, error)
  54. }
  55. type smartSiteLogClient struct {
  56. cc grpc.ClientConnInterface
  57. }
  58. func NewSmartSiteLogClient(cc grpc.ClientConnInterface) SmartSiteLogClient {
  59. return &smartSiteLogClient{cc}
  60. }
  61. func (c *smartSiteLogClient) LogAdd(ctx context.Context, in *v1.LogAddRequest, opts ...grpc.CallOption) (*v1.LogAddReply, error) {
  62. out := new(v1.LogAddReply)
  63. err := c.cc.Invoke(ctx, "/pb.SmartSiteLog/LogAdd", in, out, opts...)
  64. if err != nil {
  65. return nil, err
  66. }
  67. return out, nil
  68. }
  69. func (c *smartSiteLogClient) LogList(ctx context.Context, in *v1.LogListRequest, opts ...grpc.CallOption) (*v1.LogListReply, error) {
  70. out := new(v1.LogListReply)
  71. err := c.cc.Invoke(ctx, "/pb.SmartSiteLog/LogList", in, out, opts...)
  72. if err != nil {
  73. return nil, err
  74. }
  75. return out, nil
  76. }
  77. // SmartSiteLogServer is the server API for SmartSiteLog service.
  78. type SmartSiteLogServer interface {
  79. LogAdd(context.Context, *v1.LogAddRequest) (*v1.LogAddReply, error)
  80. LogList(context.Context, *v1.LogListRequest) (*v1.LogListReply, error)
  81. }
  82. // UnimplementedSmartSiteLogServer can be embedded to have forward compatible implementations.
  83. type UnimplementedSmartSiteLogServer struct {
  84. }
  85. func (*UnimplementedSmartSiteLogServer) LogAdd(ctx context.Context, req *v1.LogAddRequest) (*v1.LogAddReply, error) {
  86. return nil, status.Errorf(codes.Unimplemented, "method LogAdd not implemented")
  87. }
  88. func (*UnimplementedSmartSiteLogServer) LogList(ctx context.Context, req *v1.LogListRequest) (*v1.LogListReply, error) {
  89. return nil, status.Errorf(codes.Unimplemented, "method LogList not implemented")
  90. }
  91. func RegisterSmartSiteLogServer(s *grpc.Server, srv SmartSiteLogServer) {
  92. s.RegisterService(&_SmartSiteLog_serviceDesc, srv)
  93. }
  94. func _SmartSiteLog_LogAdd_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  95. in := new(v1.LogAddRequest)
  96. if err := dec(in); err != nil {
  97. return nil, err
  98. }
  99. if interceptor == nil {
  100. return srv.(SmartSiteLogServer).LogAdd(ctx, in)
  101. }
  102. info := &grpc.UnaryServerInfo{
  103. Server: srv,
  104. FullMethod: "/pb.SmartSiteLog/LogAdd",
  105. }
  106. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  107. return srv.(SmartSiteLogServer).LogAdd(ctx, req.(*v1.LogAddRequest))
  108. }
  109. return interceptor(ctx, in, info, handler)
  110. }
  111. func _SmartSiteLog_LogList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  112. in := new(v1.LogListRequest)
  113. if err := dec(in); err != nil {
  114. return nil, err
  115. }
  116. if interceptor == nil {
  117. return srv.(SmartSiteLogServer).LogList(ctx, in)
  118. }
  119. info := &grpc.UnaryServerInfo{
  120. Server: srv,
  121. FullMethod: "/pb.SmartSiteLog/LogList",
  122. }
  123. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  124. return srv.(SmartSiteLogServer).LogList(ctx, req.(*v1.LogListRequest))
  125. }
  126. return interceptor(ctx, in, info, handler)
  127. }
  128. var _SmartSiteLog_serviceDesc = grpc.ServiceDesc{
  129. ServiceName: "pb.SmartSiteLog",
  130. HandlerType: (*SmartSiteLogServer)(nil),
  131. Methods: []grpc.MethodDesc{
  132. {
  133. MethodName: "LogAdd",
  134. Handler: _SmartSiteLog_LogAdd_Handler,
  135. },
  136. {
  137. MethodName: "LogList",
  138. Handler: _SmartSiteLog_LogList_Handler,
  139. },
  140. },
  141. Streams: []grpc.StreamDesc{},
  142. Metadata: "log_service.proto",
  143. }