123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127 |
- // Code generated by protoc-gen-go. DO NOT EDIT.
- // source: thirdparty_management.proto
- // package声明符,用来防止不同的消息类型有命名冲突
- package pb
- import (
- context "context"
- fmt "fmt"
- proto "github.com/golang/protobuf/proto"
- grpc "google.golang.org/grpc"
- codes "google.golang.org/grpc/codes"
- status "google.golang.org/grpc/status"
- math "math"
- v1 "smart-alarm/pb/v1"
- )
- // Reference imports to suppress errors if they are not otherwise used.
- var _ = proto.Marshal
- var _ = fmt.Errorf
- var _ = math.Inf
- // This is a compile-time assertion to ensure that this generated file
- // is compatible with the proto package it is being compiled against.
- // A compilation error at this line likely means your copy of the
- // proto package needs to be updated.
- const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
- func init() {
- proto.RegisterFile("thirdparty_management.proto", fileDescriptor_f3d34336399aea71)
- }
- var fileDescriptor_f3d34336399aea71 = []byte{
- // 138 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2e, 0xc9, 0xc8, 0x2c,
- 0x4a, 0x29, 0x48, 0x2c, 0x2a, 0xa9, 0x8c, 0xcf, 0x4d, 0xcc, 0x4b, 0x4c, 0x4f, 0xcd, 0x4d, 0xcd,
- 0x2b, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x2a, 0x48, 0x92, 0x12, 0x2e, 0x33, 0xd4,
- 0x47, 0xa8, 0x81, 0x48, 0x18, 0xf9, 0x71, 0x09, 0x07, 0xe7, 0x26, 0x16, 0x95, 0x04, 0x67, 0x96,
- 0xa4, 0x86, 0xc0, 0x25, 0x85, 0xcc, 0xb9, 0x38, 0x83, 0x53, 0xf3, 0x52, 0x1c, 0x73, 0x12, 0x8b,
- 0x72, 0x85, 0x44, 0xf4, 0xca, 0x0c, 0xf5, 0xe0, 0xdc, 0xa0, 0xd4, 0xc2, 0xd2, 0xd4, 0xe2, 0x12,
- 0x29, 0x21, 0x34, 0xd1, 0x82, 0x9c, 0x4a, 0x25, 0x06, 0x27, 0x81, 0x28, 0xbe, 0x62, 0x90, 0x79,
- 0xba, 0x89, 0x20, 0x51, 0xfd, 0x82, 0xa4, 0x24, 0x36, 0xb0, 0x45, 0xc6, 0x80, 0x00, 0x00, 0x00,
- 0xff, 0xff, 0xc2, 0x53, 0xa9, 0x5a, 0xa0, 0x00, 0x00, 0x00,
- }
- // Reference imports to suppress errors if they are not otherwise used.
- var _ context.Context
- var _ grpc.ClientConnInterface
- // This is a compile-time assertion to ensure that this generated file
- // is compatible with the grpc package it is being compiled against.
- const _ = grpc.SupportPackageIsVersion6
- // SmartSiteThirdpartyClient is the client API for SmartSiteThirdparty service.
- //
- // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
- type SmartSiteThirdpartyClient interface {
- // 发送告警
- SendAlarm(ctx context.Context, in *v1.SendAlarmRequest, opts ...grpc.CallOption) (*v1.SendAlarmReply, error)
- }
- type smartSiteThirdpartyClient struct {
- cc grpc.ClientConnInterface
- }
- func NewSmartSiteThirdpartyClient(cc grpc.ClientConnInterface) SmartSiteThirdpartyClient {
- return &smartSiteThirdpartyClient{cc}
- }
- func (c *smartSiteThirdpartyClient) SendAlarm(ctx context.Context, in *v1.SendAlarmRequest, opts ...grpc.CallOption) (*v1.SendAlarmReply, error) {
- out := new(v1.SendAlarmReply)
- err := c.cc.Invoke(ctx, "/pb.SmartSiteThirdparty/SendAlarm", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- // SmartSiteThirdpartyServer is the server API for SmartSiteThirdparty service.
- type SmartSiteThirdpartyServer interface {
- // 发送告警
- SendAlarm(context.Context, *v1.SendAlarmRequest) (*v1.SendAlarmReply, error)
- }
- // UnimplementedSmartSiteThirdpartyServer can be embedded to have forward compatible implementations.
- type UnimplementedSmartSiteThirdpartyServer struct {
- }
- func (*UnimplementedSmartSiteThirdpartyServer) SendAlarm(ctx context.Context, req *v1.SendAlarmRequest) (*v1.SendAlarmReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method SendAlarm not implemented")
- }
- func RegisterSmartSiteThirdpartyServer(s *grpc.Server, srv SmartSiteThirdpartyServer) {
- s.RegisterService(&_SmartSiteThirdparty_serviceDesc, srv)
- }
- func _SmartSiteThirdparty_SendAlarm_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.SendAlarmRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(SmartSiteThirdpartyServer).SendAlarm(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.SmartSiteThirdparty/SendAlarm",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(SmartSiteThirdpartyServer).SendAlarm(ctx, req.(*v1.SendAlarmRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- var _SmartSiteThirdparty_serviceDesc = grpc.ServiceDesc{
- ServiceName: "pb.SmartSiteThirdparty",
- HandlerType: (*SmartSiteThirdpartyServer)(nil),
- Methods: []grpc.MethodDesc{
- {
- MethodName: "SendAlarm",
- Handler: _SmartSiteThirdparty_SendAlarm_Handler,
- },
- },
- Streams: []grpc.StreamDesc{},
- Metadata: "thirdparty_management.proto",
- }
|