Documentation ¶
Overview ¶
Package gatev1 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Package gatev1 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Constants
- Variables
- func RegisterGateCallbackServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterGateCallbackServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GateCallbackServiceClient) error
- func RegisterGateCallbackServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterGateCallbackServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server GateCallbackServiceServer) error
- func RegisterGateCallbackServiceServer(s grpc.ServiceRegistrar, srv GateCallbackServiceServer)
- func RegisterGateManagerServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterGateManagerServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GateManagerServiceClient) error
- func RegisterGateManagerServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterGateManagerServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server GateManagerServiceServer) error
- func RegisterGateManagerServiceServer(s grpc.ServiceRegistrar, srv GateManagerServiceServer)
- type AccessMethod
- func (AccessMethod) Descriptor() protoreflect.EnumDescriptor
- func (x AccessMethod) Enum() *AccessMethod
- func (AccessMethod) EnumDescriptor() ([]byte, []int)deprecated
- func (x AccessMethod) Number() protoreflect.EnumNumber
- func (x AccessMethod) String() string
- func (AccessMethod) Type() protoreflect.EnumType
- type Direction
- type GateCallbackServiceClient
- type GateCallbackServiceServer
- type GateManagerServiceClient
- type GateManagerServiceServer
- type GateType
- type PostCampusGateEventCallbackRequest
- func (*PostCampusGateEventCallbackRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PostCampusGateEventCallbackRequest) GetData() *PostCampusGateEventCallbackRequest_Data
- func (x *PostCampusGateEventCallbackRequest) GetService() string
- func (*PostCampusGateEventCallbackRequest) ProtoMessage()
- func (x *PostCampusGateEventCallbackRequest) ProtoReflect() protoreflect.Message
- func (x *PostCampusGateEventCallbackRequest) Reset()
- func (x *PostCampusGateEventCallbackRequest) String() string
- type PostCampusGateEventCallbackRequest_Data
- func (*PostCampusGateEventCallbackRequest_Data) Descriptor() ([]byte, []int)deprecated
- func (x *PostCampusGateEventCallbackRequest_Data) GetDeviceId() string
- func (x *PostCampusGateEventCallbackRequest_Data) GetDirection() string
- func (x *PostCampusGateEventCallbackRequest_Data) GetStaffId() string
- func (x *PostCampusGateEventCallbackRequest_Data) GetStaffName() string
- func (x *PostCampusGateEventCallbackRequest_Data) GetStaffType() string
- func (x *PostCampusGateEventCallbackRequest_Data) GetTime() string
- func (*PostCampusGateEventCallbackRequest_Data) ProtoMessage()
- func (x *PostCampusGateEventCallbackRequest_Data) ProtoReflect() protoreflect.Message
- func (x *PostCampusGateEventCallbackRequest_Data) Reset()
- func (x *PostCampusGateEventCallbackRequest_Data) String() string
- type PostCampusGateEventCallbackResponse
- func (*PostCampusGateEventCallbackResponse) Descriptor() ([]byte, []int)deprecated
- func (x *PostCampusGateEventCallbackResponse) GetMessage() string
- func (*PostCampusGateEventCallbackResponse) ProtoMessage()
- func (x *PostCampusGateEventCallbackResponse) ProtoReflect() protoreflect.Message
- func (x *PostCampusGateEventCallbackResponse) Reset()
- func (x *PostCampusGateEventCallbackResponse) String() string
- type PostGateEventCallbackRequest
- func (*PostGateEventCallbackRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PostGateEventCallbackRequest) GetDirection() Direction
- func (x *PostGateEventCallbackRequest) GetGateName() string
- func (x *PostGateEventCallbackRequest) GetGateType() GateType
- func (x *PostGateEventCallbackRequest) GetMethod() AccessMethod
- func (x *PostGateEventCallbackRequest) GetService() Service
- func (x *PostGateEventCallbackRequest) GetStaffId() string
- func (x *PostGateEventCallbackRequest) GetStaffName() string
- func (x *PostGateEventCallbackRequest) GetTime() *timestamppb.Timestamp
- func (*PostGateEventCallbackRequest) ProtoMessage()
- func (x *PostGateEventCallbackRequest) ProtoReflect() protoreflect.Message
- func (x *PostGateEventCallbackRequest) Reset()
- func (x *PostGateEventCallbackRequest) String() string
- type PostGateEventCallbackResponse
- func (*PostGateEventCallbackResponse) Descriptor() ([]byte, []int)deprecated
- func (x *PostGateEventCallbackResponse) GetError() int32
- func (x *PostGateEventCallbackResponse) GetMsg() string
- func (*PostGateEventCallbackResponse) ProtoMessage()
- func (x *PostGateEventCallbackResponse) ProtoReflect() protoreflect.Message
- func (x *PostGateEventCallbackResponse) Reset()
- func (x *PostGateEventCallbackResponse) String() string
- type PostRegisterGateEventRequest
- func (*PostRegisterGateEventRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PostRegisterGateEventRequest) GetCallbackEndpoint() string
- func (x *PostRegisterGateEventRequest) GetEndTime() *timestamppb.Timestamp
- func (x *PostRegisterGateEventRequest) GetStaffId() string
- func (x *PostRegisterGateEventRequest) GetStartTime() *timestamppb.Timestamp
- func (x *PostRegisterGateEventRequest) GetTriggerGateTypes() []GateType
- func (*PostRegisterGateEventRequest) ProtoMessage()
- func (x *PostRegisterGateEventRequest) ProtoReflect() protoreflect.Message
- func (x *PostRegisterGateEventRequest) Reset()
- func (x *PostRegisterGateEventRequest) String() string
- type PostRegisterGateEventResponse
- func (*PostRegisterGateEventResponse) Descriptor() ([]byte, []int)deprecated
- func (*PostRegisterGateEventResponse) ProtoMessage()
- func (x *PostRegisterGateEventResponse) ProtoReflect() protoreflect.Message
- func (x *PostRegisterGateEventResponse) Reset()
- func (x *PostRegisterGateEventResponse) String() string
- type PostStudentGateAccessRequest
- func (*PostStudentGateAccessRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PostStudentGateAccessRequest) GetDayOffName() string
- func (x *PostStudentGateAccessRequest) GetDayOffType() string
- func (x *PostStudentGateAccessRequest) GetStaffId() string
- func (x *PostStudentGateAccessRequest) GetTarget() string
- func (x *PostStudentGateAccessRequest) GetTimeEnd() string
- func (x *PostStudentGateAccessRequest) GetTimeStart() string
- func (x *PostStudentGateAccessRequest) GetUid() string
- func (*PostStudentGateAccessRequest) ProtoMessage()
- func (x *PostStudentGateAccessRequest) ProtoReflect() protoreflect.Message
- func (x *PostStudentGateAccessRequest) Reset()
- func (x *PostStudentGateAccessRequest) String() string
- type PostStudentGateAccessResponse
- func (*PostStudentGateAccessResponse) Descriptor() ([]byte, []int)deprecated
- func (x *PostStudentGateAccessResponse) GetDone() bool
- func (x *PostStudentGateAccessResponse) GetMessage() string
- func (*PostStudentGateAccessResponse) ProtoMessage()
- func (x *PostStudentGateAccessResponse) ProtoReflect() protoreflect.Message
- func (x *PostStudentGateAccessResponse) Reset()
- func (x *PostStudentGateAccessResponse) String() string
- type Service
- func (x Service) Chinese() string
- func (Service) Descriptor() protoreflect.EnumDescriptor
- func (x Service) Enum() *Service
- func (Service) EnumDescriptor() ([]byte, []int)deprecated
- func (x Service) Number() protoreflect.EnumNumber
- func (x Service) String() string
- func (Service) Type() protoreflect.EnumType
- type UnimplementedGateCallbackServiceServer
- type UnimplementedGateManagerServiceServer
- func (UnimplementedGateManagerServiceServer) PostCampusGateEventCallback(context.Context, *PostCampusGateEventCallbackRequest) (*PostCampusGateEventCallbackResponse, error)
- func (UnimplementedGateManagerServiceServer) PostRegisterGateEvent(context.Context, *PostRegisterGateEventRequest) (*PostRegisterGateEventResponse, error)
- func (UnimplementedGateManagerServiceServer) PostStudentGateAccess(context.Context, *PostStudentGateAccessRequest) (*PostStudentGateAccessResponse, error)
- type UnsafeGateCallbackServiceServer
- type UnsafeGateManagerServiceServer
Constants ¶
const ( GateManagerService_PostCampusGateEventCallback_FullMethodName = "/campusapis.gate.v1.GateManagerService/PostCampusGateEventCallback" GateManagerService_PostStudentGateAccess_FullMethodName = "/campusapis.gate.v1.GateManagerService/PostStudentGateAccess" GateManagerService_PostRegisterGateEvent_FullMethodName = "/campusapis.gate.v1.GateManagerService/PostRegisterGateEvent" )
const (
GateCallbackService_PostGateEventCallback_FullMethodName = "/campusapis.gate.v1.GateCallbackService/PostGateEventCallback"
)
Variables ¶
var ( Service_name = map[int32]string{ 0: "SERVICE_UNSPECIFIED", 1: "SERVICE_HIKVISION", 2: "SERVICE_UNIVIEW", 3: "SERVICE_BACK_OFFICE", } Service_value = map[string]int32{ "SERVICE_UNSPECIFIED": 0, "SERVICE_HIKVISION": 1, "SERVICE_UNIVIEW": 2, "SERVICE_BACK_OFFICE": 3, } )
Enum value maps for Service.
var ( Direction_name = map[int32]string{ 0: "DIRECTION_UNSPECIFIED", 1: "DIRECTION_IN", 2: "DIRECTION_OUT", } Direction_value = map[string]int32{ "DIRECTION_UNSPECIFIED": 0, "DIRECTION_IN": 1, "DIRECTION_OUT": 2, } )
Enum value maps for Direction.
var ( GateType_name = map[int32]string{ 0: "GATE_TYPE_UNSPECIFIED", 1: "GATE_TYPE_CAMPUS", 2: "GATE_TYPE_DORMITORY", 3: "GATE_TYPE_LIBRARY", } GateType_value = map[string]int32{ "GATE_TYPE_UNSPECIFIED": 0, "GATE_TYPE_CAMPUS": 1, "GATE_TYPE_DORMITORY": 2, "GATE_TYPE_LIBRARY": 3, } )
Enum value maps for GateType.
var ( AccessMethod_name = map[int32]string{ 0: "ACCESS_METHOD_UNSPECIFIED", 1: "ACCESS_METHOD_SCHOOL_CARD", 2: "ACCESS_METHOD_FACE", } AccessMethod_value = map[string]int32{ "ACCESS_METHOD_UNSPECIFIED": 0, "ACCESS_METHOD_SCHOOL_CARD": 1, "ACCESS_METHOD_FACE": 2, } )
Enum value maps for AccessMethod.
var File_campusapis_gate_v1_callback_proto protoreflect.FileDescriptor
var File_campusapis_gate_v1_defined_proto protoreflect.FileDescriptor
var File_campusapis_gate_v1_manager_proto protoreflect.FileDescriptor
var GateCallbackService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "campusapis.gate.v1.GateCallbackService", HandlerType: (*GateCallbackServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "PostGateEventCallback", Handler: _GateCallbackService_PostGateEventCallback_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "campusapis/gate/v1/callback.proto", }
GateCallbackService_ServiceDesc is the grpc.ServiceDesc for GateCallbackService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var GateManagerService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "campusapis.gate.v1.GateManagerService", HandlerType: (*GateManagerServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "PostCampusGateEventCallback", Handler: _GateManagerService_PostCampusGateEventCallback_Handler, }, { MethodName: "PostStudentGateAccess", Handler: _GateManagerService_PostStudentGateAccess_Handler, }, { MethodName: "PostRegisterGateEvent", Handler: _GateManagerService_PostRegisterGateEvent_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "campusapis/gate/v1/manager.proto", }
GateManagerService_ServiceDesc is the grpc.ServiceDesc for GateManagerService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterGateCallbackServiceHandler ¶
func RegisterGateCallbackServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterGateCallbackServiceHandler registers the http handlers for service GateCallbackService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterGateCallbackServiceHandlerClient ¶
func RegisterGateCallbackServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GateCallbackServiceClient) error
RegisterGateCallbackServiceHandlerClient registers the http handlers for service GateCallbackService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "GateCallbackServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "GateCallbackServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "GateCallbackServiceClient" to call the correct interceptors. This client ignores the HTTP middlewares.
func RegisterGateCallbackServiceHandlerFromEndpoint ¶
func RegisterGateCallbackServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterGateCallbackServiceHandlerFromEndpoint is same as RegisterGateCallbackServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterGateCallbackServiceHandlerServer ¶
func RegisterGateCallbackServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server GateCallbackServiceServer) error
RegisterGateCallbackServiceHandlerServer registers the http handlers for service GateCallbackService to "mux". UnaryRPC :call GateCallbackServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterGateCallbackServiceHandlerFromEndpoint instead. GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call.
func RegisterGateCallbackServiceServer ¶
func RegisterGateCallbackServiceServer(s grpc.ServiceRegistrar, srv GateCallbackServiceServer)
func RegisterGateManagerServiceHandler ¶
func RegisterGateManagerServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterGateManagerServiceHandler registers the http handlers for service GateManagerService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterGateManagerServiceHandlerClient ¶
func RegisterGateManagerServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GateManagerServiceClient) error
RegisterGateManagerServiceHandlerClient registers the http handlers for service GateManagerService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "GateManagerServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "GateManagerServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "GateManagerServiceClient" to call the correct interceptors. This client ignores the HTTP middlewares.
func RegisterGateManagerServiceHandlerFromEndpoint ¶
func RegisterGateManagerServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterGateManagerServiceHandlerFromEndpoint is same as RegisterGateManagerServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterGateManagerServiceHandlerServer ¶
func RegisterGateManagerServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server GateManagerServiceServer) error
RegisterGateManagerServiceHandlerServer registers the http handlers for service GateManagerService to "mux". UnaryRPC :call GateManagerServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterGateManagerServiceHandlerFromEndpoint instead. GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call.
func RegisterGateManagerServiceServer ¶
func RegisterGateManagerServiceServer(s grpc.ServiceRegistrar, srv GateManagerServiceServer)
Types ¶
type AccessMethod ¶
type AccessMethod int32
通过方式
const ( AccessMethod_ACCESS_METHOD_UNSPECIFIED AccessMethod = 0 // 校园卡 AccessMethod_ACCESS_METHOD_SCHOOL_CARD AccessMethod = 1 // 人脸识别 AccessMethod_ACCESS_METHOD_FACE AccessMethod = 2 )
func (AccessMethod) Descriptor ¶
func (AccessMethod) Descriptor() protoreflect.EnumDescriptor
func (AccessMethod) Enum ¶
func (x AccessMethod) Enum() *AccessMethod
func (AccessMethod) EnumDescriptor
deprecated
func (AccessMethod) EnumDescriptor() ([]byte, []int)
Deprecated: Use AccessMethod.Descriptor instead.
func (AccessMethod) Number ¶
func (x AccessMethod) Number() protoreflect.EnumNumber
func (AccessMethod) String ¶
func (x AccessMethod) String() string
func (AccessMethod) Type ¶
func (AccessMethod) Type() protoreflect.EnumType
type Direction ¶
type Direction int32
以门禁限制活动/保护的区域为主体的进出方向
func (Direction) Descriptor ¶
func (Direction) Descriptor() protoreflect.EnumDescriptor
func (Direction) EnumDescriptor
deprecated
func (Direction) Number ¶
func (x Direction) Number() protoreflect.EnumNumber
func (Direction) Type ¶
func (Direction) Type() protoreflect.EnumType
type GateCallbackServiceClient ¶
type GateCallbackServiceClient interface { // 门禁事件回调接口 PostGateEventCallback(ctx context.Context, in *PostGateEventCallbackRequest, opts ...grpc.CallOption) (*PostGateEventCallbackResponse, error) }
GateCallbackServiceClient is the client API for GateCallbackService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
门禁回调服务,由需要门禁回调事件的服务实现
func NewGateCallbackServiceClient ¶
func NewGateCallbackServiceClient(cc grpc.ClientConnInterface) GateCallbackServiceClient
type GateCallbackServiceServer ¶
type GateCallbackServiceServer interface { // 门禁事件回调接口 PostGateEventCallback(context.Context, *PostGateEventCallbackRequest) (*PostGateEventCallbackResponse, error) // contains filtered or unexported methods }
GateCallbackServiceServer is the server API for GateCallbackService service. All implementations must embed UnimplementedGateCallbackServiceServer for forward compatibility.
门禁回调服务,由需要门禁回调事件的服务实现
type GateManagerServiceClient ¶
type GateManagerServiceClient interface { // 门禁回调,给第三方服务使用 PostCampusGateEventCallback(ctx context.Context, in *PostCampusGateEventCallbackRequest, opts ...grpc.CallOption) (*PostCampusGateEventCallbackResponse, error) // 推送学生门禁通行信息,仅供内部服务调用 PostStudentGateAccess(ctx context.Context, in *PostStudentGateAccessRequest, opts ...grpc.CallOption) (*PostStudentGateAccessResponse, error) // 注册门禁事件回调至应用,仅供内部服务调用,对应服务需要实现GateCallbackService服务,重复推送视为累加 PostRegisterGateEvent(ctx context.Context, in *PostRegisterGateEventRequest, opts ...grpc.CallOption) (*PostRegisterGateEventResponse, error) }
GateManagerServiceClient is the client API for GateManagerService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
门禁服务管理端
func NewGateManagerServiceClient ¶
func NewGateManagerServiceClient(cc grpc.ClientConnInterface) GateManagerServiceClient
type GateManagerServiceServer ¶
type GateManagerServiceServer interface { // 门禁回调,给第三方服务使用 PostCampusGateEventCallback(context.Context, *PostCampusGateEventCallbackRequest) (*PostCampusGateEventCallbackResponse, error) // 推送学生门禁通行信息,仅供内部服务调用 PostStudentGateAccess(context.Context, *PostStudentGateAccessRequest) (*PostStudentGateAccessResponse, error) // 注册门禁事件回调至应用,仅供内部服务调用,对应服务需要实现GateCallbackService服务,重复推送视为累加 PostRegisterGateEvent(context.Context, *PostRegisterGateEventRequest) (*PostRegisterGateEventResponse, error) // contains filtered or unexported methods }
GateManagerServiceServer is the server API for GateManagerService service. All implementations must embed UnimplementedGateManagerServiceServer for forward compatibility.
门禁服务管理端
type GateType ¶
type GateType int32
门禁类型
func (GateType) Descriptor ¶
func (GateType) Descriptor() protoreflect.EnumDescriptor
func (GateType) EnumDescriptor
deprecated
func (GateType) Number ¶
func (x GateType) Number() protoreflect.EnumNumber
func (GateType) Type ¶
func (GateType) Type() protoreflect.EnumType
type PostCampusGateEventCallbackRequest ¶
type PostCampusGateEventCallbackRequest struct { Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service,omitempty"` Data *PostCampusGateEventCallbackRequest_Data `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` // contains filtered or unexported fields }
门禁回调请求体
func (*PostCampusGateEventCallbackRequest) Descriptor
deprecated
func (*PostCampusGateEventCallbackRequest) Descriptor() ([]byte, []int)
Deprecated: Use PostCampusGateEventCallbackRequest.ProtoReflect.Descriptor instead.
func (*PostCampusGateEventCallbackRequest) GetData ¶
func (x *PostCampusGateEventCallbackRequest) GetData() *PostCampusGateEventCallbackRequest_Data
func (*PostCampusGateEventCallbackRequest) GetService ¶
func (x *PostCampusGateEventCallbackRequest) GetService() string
func (*PostCampusGateEventCallbackRequest) ProtoMessage ¶
func (*PostCampusGateEventCallbackRequest) ProtoMessage()
func (*PostCampusGateEventCallbackRequest) ProtoReflect ¶
func (x *PostCampusGateEventCallbackRequest) ProtoReflect() protoreflect.Message
func (*PostCampusGateEventCallbackRequest) Reset ¶
func (x *PostCampusGateEventCallbackRequest) Reset()
func (*PostCampusGateEventCallbackRequest) String ¶
func (x *PostCampusGateEventCallbackRequest) String() string
type PostCampusGateEventCallbackRequest_Data ¶
type PostCampusGateEventCallbackRequest_Data struct { StaffId string `protobuf:"bytes,1,opt,name=staff_id,json=staffId,proto3" json:"staff_id,omitempty"` StaffName string `protobuf:"bytes,2,opt,name=staff_name,json=staffName,proto3" json:"staff_name,omitempty"` DeviceId string `protobuf:"bytes,3,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"` Time string `protobuf:"bytes,4,opt,name=time,proto3" json:"time,omitempty"` Direction string `protobuf:"bytes,5,opt,name=direction,proto3" json:"direction,omitempty"` StaffType string `protobuf:"bytes,6,opt,name=staff_type,json=staffType,proto3" json:"staff_type,omitempty"` // contains filtered or unexported fields }
func (*PostCampusGateEventCallbackRequest_Data) Descriptor
deprecated
func (*PostCampusGateEventCallbackRequest_Data) Descriptor() ([]byte, []int)
Deprecated: Use PostCampusGateEventCallbackRequest_Data.ProtoReflect.Descriptor instead.
func (*PostCampusGateEventCallbackRequest_Data) GetDeviceId ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetDeviceId() string
func (*PostCampusGateEventCallbackRequest_Data) GetDirection ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetDirection() string
func (*PostCampusGateEventCallbackRequest_Data) GetStaffId ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetStaffId() string
func (*PostCampusGateEventCallbackRequest_Data) GetStaffName ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetStaffName() string
func (*PostCampusGateEventCallbackRequest_Data) GetStaffType ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetStaffType() string
func (*PostCampusGateEventCallbackRequest_Data) GetTime ¶
func (x *PostCampusGateEventCallbackRequest_Data) GetTime() string
func (*PostCampusGateEventCallbackRequest_Data) ProtoMessage ¶
func (*PostCampusGateEventCallbackRequest_Data) ProtoMessage()
func (*PostCampusGateEventCallbackRequest_Data) ProtoReflect ¶
func (x *PostCampusGateEventCallbackRequest_Data) ProtoReflect() protoreflect.Message
func (*PostCampusGateEventCallbackRequest_Data) Reset ¶
func (x *PostCampusGateEventCallbackRequest_Data) Reset()
func (*PostCampusGateEventCallbackRequest_Data) String ¶
func (x *PostCampusGateEventCallbackRequest_Data) String() string
type PostCampusGateEventCallbackResponse ¶
type PostCampusGateEventCallbackResponse struct { Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` // contains filtered or unexported fields }
门禁回调返回体
func (*PostCampusGateEventCallbackResponse) Descriptor
deprecated
func (*PostCampusGateEventCallbackResponse) Descriptor() ([]byte, []int)
Deprecated: Use PostCampusGateEventCallbackResponse.ProtoReflect.Descriptor instead.
func (*PostCampusGateEventCallbackResponse) GetMessage ¶
func (x *PostCampusGateEventCallbackResponse) GetMessage() string
func (*PostCampusGateEventCallbackResponse) ProtoMessage ¶
func (*PostCampusGateEventCallbackResponse) ProtoMessage()
func (*PostCampusGateEventCallbackResponse) ProtoReflect ¶
func (x *PostCampusGateEventCallbackResponse) ProtoReflect() protoreflect.Message
func (*PostCampusGateEventCallbackResponse) Reset ¶
func (x *PostCampusGateEventCallbackResponse) Reset()
func (*PostCampusGateEventCallbackResponse) String ¶
func (x *PostCampusGateEventCallbackResponse) String() string
type PostGateEventCallbackRequest ¶
type PostGateEventCallbackRequest struct { StaffId string `protobuf:"bytes,1,opt,name=staff_id,json=staffId,proto3" json:"staff_id,omitempty"` StaffName string `protobuf:"bytes,2,opt,name=staff_name,json=staffName,proto3" json:"staff_name,omitempty"` // 事件时间 Time *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=time,proto3" json:"time,omitempty"` // 门禁名称 GateName string `protobuf:"bytes,4,opt,name=gate_name,json=gateName,proto3" json:"gate_name,omitempty"` GateType GateType `protobuf:"varint,5,opt,name=gate_type,json=gateType,proto3,enum=campusapis.gate.v1.GateType" json:"gate_type,omitempty"` Direction Direction `protobuf:"varint,6,opt,name=direction,proto3,enum=campusapis.gate.v1.Direction" json:"direction,omitempty"` Service Service `protobuf:"varint,7,opt,name=service,proto3,enum=campusapis.gate.v1.Service" json:"service,omitempty"` Method AccessMethod `protobuf:"varint,8,opt,name=method,proto3,enum=campusapis.gate.v1.AccessMethod" json:"method,omitempty"` // contains filtered or unexported fields }
推送门禁事件回调请求体
func (*PostGateEventCallbackRequest) Descriptor
deprecated
func (*PostGateEventCallbackRequest) Descriptor() ([]byte, []int)
Deprecated: Use PostGateEventCallbackRequest.ProtoReflect.Descriptor instead.
func (*PostGateEventCallbackRequest) GetDirection ¶
func (x *PostGateEventCallbackRequest) GetDirection() Direction
func (*PostGateEventCallbackRequest) GetGateName ¶
func (x *PostGateEventCallbackRequest) GetGateName() string
func (*PostGateEventCallbackRequest) GetGateType ¶
func (x *PostGateEventCallbackRequest) GetGateType() GateType
func (*PostGateEventCallbackRequest) GetMethod ¶
func (x *PostGateEventCallbackRequest) GetMethod() AccessMethod
func (*PostGateEventCallbackRequest) GetService ¶
func (x *PostGateEventCallbackRequest) GetService() Service
func (*PostGateEventCallbackRequest) GetStaffId ¶
func (x *PostGateEventCallbackRequest) GetStaffId() string
func (*PostGateEventCallbackRequest) GetStaffName ¶
func (x *PostGateEventCallbackRequest) GetStaffName() string
func (*PostGateEventCallbackRequest) GetTime ¶
func (x *PostGateEventCallbackRequest) GetTime() *timestamppb.Timestamp
func (*PostGateEventCallbackRequest) ProtoMessage ¶
func (*PostGateEventCallbackRequest) ProtoMessage()
func (*PostGateEventCallbackRequest) ProtoReflect ¶
func (x *PostGateEventCallbackRequest) ProtoReflect() protoreflect.Message
func (*PostGateEventCallbackRequest) Reset ¶
func (x *PostGateEventCallbackRequest) Reset()
func (*PostGateEventCallbackRequest) String ¶
func (x *PostGateEventCallbackRequest) String() string
type PostGateEventCallbackResponse ¶
type PostGateEventCallbackResponse struct { Error int32 `protobuf:"varint,1,opt,name=error,proto3" json:"error,omitempty"` Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"` // contains filtered or unexported fields }
推送门禁事件回调返回体
func (*PostGateEventCallbackResponse) Descriptor
deprecated
func (*PostGateEventCallbackResponse) Descriptor() ([]byte, []int)
Deprecated: Use PostGateEventCallbackResponse.ProtoReflect.Descriptor instead.
func (*PostGateEventCallbackResponse) GetError ¶
func (x *PostGateEventCallbackResponse) GetError() int32
func (*PostGateEventCallbackResponse) GetMsg ¶
func (x *PostGateEventCallbackResponse) GetMsg() string
func (*PostGateEventCallbackResponse) ProtoMessage ¶
func (*PostGateEventCallbackResponse) ProtoMessage()
func (*PostGateEventCallbackResponse) ProtoReflect ¶
func (x *PostGateEventCallbackResponse) ProtoReflect() protoreflect.Message
func (*PostGateEventCallbackResponse) Reset ¶
func (x *PostGateEventCallbackResponse) Reset()
func (*PostGateEventCallbackResponse) String ¶
func (x *PostGateEventCallbackResponse) String() string
type PostRegisterGateEventRequest ¶
type PostRegisterGateEventRequest struct { StaffId string `protobuf:"bytes,1,opt,name=staff_id,json=staffId,proto3" json:"staff_id,omitempty"` // 触发门禁事件类型 TriggerGateTypes []GateType `` /* 152-byte string literal not displayed */ // hook开始时间 StartTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"` // hook结束时间 EndTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"` // 推送事件服务回调grpc端口,接口为ip:port,注意可访问性 CallbackEndpoint string `protobuf:"bytes,5,opt,name=callback_endpoint,json=callbackEndpoint,proto3" json:"callback_endpoint,omitempty"` // contains filtered or unexported fields }
门禁事件回调注册请求体
func (*PostRegisterGateEventRequest) Descriptor
deprecated
func (*PostRegisterGateEventRequest) Descriptor() ([]byte, []int)
Deprecated: Use PostRegisterGateEventRequest.ProtoReflect.Descriptor instead.
func (*PostRegisterGateEventRequest) GetCallbackEndpoint ¶
func (x *PostRegisterGateEventRequest) GetCallbackEndpoint() string
func (*PostRegisterGateEventRequest) GetEndTime ¶
func (x *PostRegisterGateEventRequest) GetEndTime() *timestamppb.Timestamp
func (*PostRegisterGateEventRequest) GetStaffId ¶
func (x *PostRegisterGateEventRequest) GetStaffId() string
func (*PostRegisterGateEventRequest) GetStartTime ¶
func (x *PostRegisterGateEventRequest) GetStartTime() *timestamppb.Timestamp
func (*PostRegisterGateEventRequest) GetTriggerGateTypes ¶
func (x *PostRegisterGateEventRequest) GetTriggerGateTypes() []GateType
func (*PostRegisterGateEventRequest) ProtoMessage ¶
func (*PostRegisterGateEventRequest) ProtoMessage()
func (*PostRegisterGateEventRequest) ProtoReflect ¶
func (x *PostRegisterGateEventRequest) ProtoReflect() protoreflect.Message
func (*PostRegisterGateEventRequest) Reset ¶
func (x *PostRegisterGateEventRequest) Reset()
func (*PostRegisterGateEventRequest) String ¶
func (x *PostRegisterGateEventRequest) String() string
type PostRegisterGateEventResponse ¶
type PostRegisterGateEventResponse struct {
// contains filtered or unexported fields
}
门禁事件回调注册返回体
func (*PostRegisterGateEventResponse) Descriptor
deprecated
func (*PostRegisterGateEventResponse) Descriptor() ([]byte, []int)
Deprecated: Use PostRegisterGateEventResponse.ProtoReflect.Descriptor instead.
func (*PostRegisterGateEventResponse) ProtoMessage ¶
func (*PostRegisterGateEventResponse) ProtoMessage()
func (*PostRegisterGateEventResponse) ProtoReflect ¶
func (x *PostRegisterGateEventResponse) ProtoReflect() protoreflect.Message
func (*PostRegisterGateEventResponse) Reset ¶
func (x *PostRegisterGateEventResponse) Reset()
func (*PostRegisterGateEventResponse) String ¶
func (x *PostRegisterGateEventResponse) String() string
type PostStudentGateAccessRequest ¶
type PostStudentGateAccessRequest struct { // 学工号(重要) StaffId string `protobuf:"bytes,1,opt,name=staffId,proto3" json:"staffId,omitempty"` // 请假类型,数字,一个数字对应一大类请假,枚举及含义: // 0->临时请假 | 1->当天假 | 2->单位实习(目前没用)| // 3->特殊(目前没用) | 4->身份码(目前没用) | // 5->离校 | 6->按周(目前没用) | 7->按月(目前没用) DayOffType string `protobuf:"bytes,2,opt,name=dayOffType,proto3" json:"dayOffType,omitempty"` // 请假类型,中文名 DayOffName string `protobuf:"bytes,3,opt,name=dayOffName,proto3" json:"dayOffName,omitempty"` // 开始时间(重要) TimeStart string `protobuf:"bytes,4,opt,name=timeStart,proto3" json:"timeStart,omitempty"` // 结束时间(重要) TimeEnd string `protobuf:"bytes,5,opt,name=timeEnd,proto3" json:"timeEnd,omitempty"` // 假条 uid Uid string `protobuf:"bytes,6,opt,name=uid,proto3" json:"uid,omitempty"` // 闸机牌子(重要),枚举及含义:hikvision -> 海康 | uniview -> 宇视 Target string `protobuf:"bytes,7,opt,name=Target,proto3" json:"Target,omitempty"` // contains filtered or unexported fields }
推送学生门禁通行信息-请求关键字
func (*PostStudentGateAccessRequest) Descriptor
deprecated
func (*PostStudentGateAccessRequest) Descriptor() ([]byte, []int)
Deprecated: Use PostStudentGateAccessRequest.ProtoReflect.Descriptor instead.
func (*PostStudentGateAccessRequest) GetDayOffName ¶
func (x *PostStudentGateAccessRequest) GetDayOffName() string
func (*PostStudentGateAccessRequest) GetDayOffType ¶
func (x *PostStudentGateAccessRequest) GetDayOffType() string
func (*PostStudentGateAccessRequest) GetStaffId ¶
func (x *PostStudentGateAccessRequest) GetStaffId() string
func (*PostStudentGateAccessRequest) GetTarget ¶
func (x *PostStudentGateAccessRequest) GetTarget() string
func (*PostStudentGateAccessRequest) GetTimeEnd ¶
func (x *PostStudentGateAccessRequest) GetTimeEnd() string
func (*PostStudentGateAccessRequest) GetTimeStart ¶
func (x *PostStudentGateAccessRequest) GetTimeStart() string
func (*PostStudentGateAccessRequest) GetUid ¶
func (x *PostStudentGateAccessRequest) GetUid() string
func (*PostStudentGateAccessRequest) ProtoMessage ¶
func (*PostStudentGateAccessRequest) ProtoMessage()
func (*PostStudentGateAccessRequest) ProtoReflect ¶
func (x *PostStudentGateAccessRequest) ProtoReflect() protoreflect.Message
func (*PostStudentGateAccessRequest) Reset ¶
func (x *PostStudentGateAccessRequest) Reset()
func (*PostStudentGateAccessRequest) String ¶
func (x *PostStudentGateAccessRequest) String() string
type PostStudentGateAccessResponse ¶
type PostStudentGateAccessResponse struct { Done bool `protobuf:"varint,1,opt,name=done,proto3" json:"done,omitempty"` //是否完成 Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` //完成信息 // contains filtered or unexported fields }
推送学生门禁通行信息
func (*PostStudentGateAccessResponse) Descriptor
deprecated
func (*PostStudentGateAccessResponse) Descriptor() ([]byte, []int)
Deprecated: Use PostStudentGateAccessResponse.ProtoReflect.Descriptor instead.
func (*PostStudentGateAccessResponse) GetDone ¶
func (x *PostStudentGateAccessResponse) GetDone() bool
func (*PostStudentGateAccessResponse) GetMessage ¶
func (x *PostStudentGateAccessResponse) GetMessage() string
func (*PostStudentGateAccessResponse) ProtoMessage ¶
func (*PostStudentGateAccessResponse) ProtoMessage()
func (*PostStudentGateAccessResponse) ProtoReflect ¶
func (x *PostStudentGateAccessResponse) ProtoReflect() protoreflect.Message
func (*PostStudentGateAccessResponse) Reset ¶
func (x *PostStudentGateAccessResponse) Reset()
func (*PostStudentGateAccessResponse) String ¶
func (x *PostStudentGateAccessResponse) String() string
type Service ¶
type Service int32
门禁服务名称,以品牌或者第三方服务商名称划分,用于出问题时摔锅
func (Service) Descriptor ¶
func (Service) Descriptor() protoreflect.EnumDescriptor
func (Service) EnumDescriptor
deprecated
func (Service) Number ¶
func (x Service) Number() protoreflect.EnumNumber
func (Service) Type ¶
func (Service) Type() protoreflect.EnumType
type UnimplementedGateCallbackServiceServer ¶
type UnimplementedGateCallbackServiceServer struct{}
UnimplementedGateCallbackServiceServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedGateCallbackServiceServer) PostGateEventCallback ¶
func (UnimplementedGateCallbackServiceServer) PostGateEventCallback(context.Context, *PostGateEventCallbackRequest) (*PostGateEventCallbackResponse, error)
type UnimplementedGateManagerServiceServer ¶
type UnimplementedGateManagerServiceServer struct{}
UnimplementedGateManagerServiceServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedGateManagerServiceServer) PostCampusGateEventCallback ¶
func (UnimplementedGateManagerServiceServer) PostCampusGateEventCallback(context.Context, *PostCampusGateEventCallbackRequest) (*PostCampusGateEventCallbackResponse, error)
func (UnimplementedGateManagerServiceServer) PostRegisterGateEvent ¶
func (UnimplementedGateManagerServiceServer) PostRegisterGateEvent(context.Context, *PostRegisterGateEventRequest) (*PostRegisterGateEventResponse, error)
func (UnimplementedGateManagerServiceServer) PostStudentGateAccess ¶
func (UnimplementedGateManagerServiceServer) PostStudentGateAccess(context.Context, *PostStudentGateAccessRequest) (*PostStudentGateAccessResponse, error)
type UnsafeGateCallbackServiceServer ¶
type UnsafeGateCallbackServiceServer interface {
// contains filtered or unexported methods
}
UnsafeGateCallbackServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to GateCallbackServiceServer will result in compilation errors.
type UnsafeGateManagerServiceServer ¶
type UnsafeGateManagerServiceServer interface {
// contains filtered or unexported methods
}
UnsafeGateManagerServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to GateManagerServiceServer will result in compilation errors.