123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325 |
- // Code generated by protoc-gen-go. DO NOT EDIT.
- // source: device_service.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 "property-mqtt/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("device_service.proto", fileDescriptor_5b575c291bff7431)
- }
- var fileDescriptor_5b575c291bff7431 = []byte{
- // 269 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xdf, 0x4a, 0xc3, 0x30,
- 0x14, 0x87, 0x05, 0x61, 0x17, 0x07, 0xff, 0xcc, 0x83, 0xc8, 0xac, 0x53, 0xc1, 0x7b, 0x3b, 0xa6,
- 0x2f, 0xa0, 0x4e, 0x26, 0x82, 0x43, 0x28, 0xa8, 0xe0, 0xcd, 0xe8, 0x9f, 0x03, 0x0b, 0xb6, 0x4d,
- 0x9a, 0x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c2, 0x17, 0xae, 0x38, 0xee, 0xf5, 0x6d, 0xf3, 0x01, 0x3f, 0x87,
- 0x4a, 0x4b, 0x45, 0x9a, 0x37, 0xd7, 0x45, 0xc5, 0x3c, 0x51, 0x49, 0x32, 0x68, 0xdf, 0xfc, 0xf6,
- 0x27, 0x00, 0x00, 0xff, 0xff, 0x3d, 0xba, 0xeb, 0x34, 0x28, 0x02, 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
- // DeviceClient is the client API for Device service.
- //
- // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
- type DeviceClient interface {
- // 门禁远程命令结果
- GateCommandResult(ctx context.Context, in *v1.GateCommandResultRequest, opts ...grpc.CallOption) (*v1.GateCommandResultReply, error)
- // 门禁在线
- GateOnline(ctx context.Context, in *v1.GateOnlineRequest, opts ...grpc.CallOption) (*v1.GateOnlineReply, error)
- // 门禁进出记录添加
- GateRecordAdd(ctx context.Context, in *v1.GateRecordAddRequest, opts ...grpc.CallOption) (*v1.GateRecordAddReply, error)
- // 人脸门禁所有id
- MqttFaceGate(ctx context.Context, in *v1.MqttFaceGateRequest, opts ...grpc.CallOption) (*v1.MqttFaceGateReply, error)
- // 门禁白名单匹配
- GateWhiteMatch(ctx context.Context, in *v1.GateWhiteMatchRequest, opts ...grpc.CallOption) (*v1.GateWhiteMatchReply, error)
- // 访客检查
- GateVisitorCheck(ctx context.Context, in *v1.GateVisitorCheckRequest, opts ...grpc.CallOption) (*v1.GateVisitorCheckReply, error)
- }
- type deviceClient struct {
- cc grpc.ClientConnInterface
- }
- func NewDeviceClient(cc grpc.ClientConnInterface) DeviceClient {
- return &deviceClient{cc}
- }
- func (c *deviceClient) GateCommandResult(ctx context.Context, in *v1.GateCommandResultRequest, opts ...grpc.CallOption) (*v1.GateCommandResultReply, error) {
- out := new(v1.GateCommandResultReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/GateCommandResult", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *deviceClient) GateOnline(ctx context.Context, in *v1.GateOnlineRequest, opts ...grpc.CallOption) (*v1.GateOnlineReply, error) {
- out := new(v1.GateOnlineReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/GateOnline", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *deviceClient) GateRecordAdd(ctx context.Context, in *v1.GateRecordAddRequest, opts ...grpc.CallOption) (*v1.GateRecordAddReply, error) {
- out := new(v1.GateRecordAddReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/GateRecordAdd", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *deviceClient) MqttFaceGate(ctx context.Context, in *v1.MqttFaceGateRequest, opts ...grpc.CallOption) (*v1.MqttFaceGateReply, error) {
- out := new(v1.MqttFaceGateReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/MqttFaceGate", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *deviceClient) GateWhiteMatch(ctx context.Context, in *v1.GateWhiteMatchRequest, opts ...grpc.CallOption) (*v1.GateWhiteMatchReply, error) {
- out := new(v1.GateWhiteMatchReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/GateWhiteMatch", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *deviceClient) GateVisitorCheck(ctx context.Context, in *v1.GateVisitorCheckRequest, opts ...grpc.CallOption) (*v1.GateVisitorCheckReply, error) {
- out := new(v1.GateVisitorCheckReply)
- err := c.cc.Invoke(ctx, "/pb.service.Device/GateVisitorCheck", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- // DeviceServer is the server API for Device service.
- type DeviceServer interface {
- // 门禁远程命令结果
- GateCommandResult(context.Context, *v1.GateCommandResultRequest) (*v1.GateCommandResultReply, error)
- // 门禁在线
- GateOnline(context.Context, *v1.GateOnlineRequest) (*v1.GateOnlineReply, error)
- // 门禁进出记录添加
- GateRecordAdd(context.Context, *v1.GateRecordAddRequest) (*v1.GateRecordAddReply, error)
- // 人脸门禁所有id
- MqttFaceGate(context.Context, *v1.MqttFaceGateRequest) (*v1.MqttFaceGateReply, error)
- // 门禁白名单匹配
- GateWhiteMatch(context.Context, *v1.GateWhiteMatchRequest) (*v1.GateWhiteMatchReply, error)
- // 访客检查
- GateVisitorCheck(context.Context, *v1.GateVisitorCheckRequest) (*v1.GateVisitorCheckReply, error)
- }
- // UnimplementedDeviceServer can be embedded to have forward compatible implementations.
- type UnimplementedDeviceServer struct {
- }
- func (*UnimplementedDeviceServer) GateCommandResult(ctx context.Context, req *v1.GateCommandResultRequest) (*v1.GateCommandResultReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GateCommandResult not implemented")
- }
- func (*UnimplementedDeviceServer) GateOnline(ctx context.Context, req *v1.GateOnlineRequest) (*v1.GateOnlineReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GateOnline not implemented")
- }
- func (*UnimplementedDeviceServer) GateRecordAdd(ctx context.Context, req *v1.GateRecordAddRequest) (*v1.GateRecordAddReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GateRecordAdd not implemented")
- }
- func (*UnimplementedDeviceServer) MqttFaceGate(ctx context.Context, req *v1.MqttFaceGateRequest) (*v1.MqttFaceGateReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method MqttFaceGate not implemented")
- }
- func (*UnimplementedDeviceServer) GateWhiteMatch(ctx context.Context, req *v1.GateWhiteMatchRequest) (*v1.GateWhiteMatchReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GateWhiteMatch not implemented")
- }
- func (*UnimplementedDeviceServer) GateVisitorCheck(ctx context.Context, req *v1.GateVisitorCheckRequest) (*v1.GateVisitorCheckReply, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GateVisitorCheck not implemented")
- }
- func RegisterDeviceServer(s *grpc.Server, srv DeviceServer) {
- s.RegisterService(&_Device_serviceDesc, srv)
- }
- func _Device_GateCommandResult_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.GateCommandResultRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).GateCommandResult(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/GateCommandResult",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).GateCommandResult(ctx, req.(*v1.GateCommandResultRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _Device_GateOnline_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.GateOnlineRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).GateOnline(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/GateOnline",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).GateOnline(ctx, req.(*v1.GateOnlineRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _Device_GateRecordAdd_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.GateRecordAddRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).GateRecordAdd(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/GateRecordAdd",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).GateRecordAdd(ctx, req.(*v1.GateRecordAddRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _Device_MqttFaceGate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.MqttFaceGateRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).MqttFaceGate(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/MqttFaceGate",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).MqttFaceGate(ctx, req.(*v1.MqttFaceGateRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _Device_GateWhiteMatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.GateWhiteMatchRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).GateWhiteMatch(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/GateWhiteMatch",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).GateWhiteMatch(ctx, req.(*v1.GateWhiteMatchRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _Device_GateVisitorCheck_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(v1.GateVisitorCheckRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(DeviceServer).GateVisitorCheck(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/pb.service.Device/GateVisitorCheck",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(DeviceServer).GateVisitorCheck(ctx, req.(*v1.GateVisitorCheckRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- var _Device_serviceDesc = grpc.ServiceDesc{
- ServiceName: "pb.service.Device",
- HandlerType: (*DeviceServer)(nil),
- Methods: []grpc.MethodDesc{
- {
- MethodName: "GateCommandResult",
- Handler: _Device_GateCommandResult_Handler,
- },
- {
- MethodName: "GateOnline",
- Handler: _Device_GateOnline_Handler,
- },
- {
- MethodName: "GateRecordAdd",
- Handler: _Device_GateRecordAdd_Handler,
- },
- {
- MethodName: "MqttFaceGate",
- Handler: _Device_MqttFaceGate_Handler,
- },
- {
- MethodName: "GateWhiteMatch",
- Handler: _Device_GateWhiteMatch_Handler,
- },
- {
- MethodName: "GateVisitorCheck",
- Handler: _Device_GateVisitorCheck_Handler,
- },
- },
- Streams: []grpc.StreamDesc{},
- Metadata: "device_service.proto",
- }
|