Documentation
¶
Index ¶
- Constants
- Variables
- type Connector
- func (c *Connector) AddDevice(sn, serialNum string, ip string, user, password string) error
- func (c *Connector) Destroy() error
- func (c *Connector) GetResultChan() chan VerifyResult
- func (c *Connector) GetSnapChan() chan SnapResult
- func (c *Connector) Initialize() error
- func (c *Connector) RemoveDevice(sn string) error
- func (c *Connector) Send(sn string, operator string, body map[string]any) (res *ResponseData, err error)
- type HeartBeat
- type RecogniseType
- type ResponseData
- type SnapResult
- type VerifyData
- type VerifyResult
Constants ¶
View Source
const ( DefaultHeartMapping = "/subscribe/heartbeat" DefaultResultMapping = "/subscribe/result" )
Variables ¶
View Source
var (
DeviceNotOnlineError = errors.New("设备不在线")
)
Functions ¶
This section is empty.
Types ¶
type Connector ¶
type Connector struct {
// contains filtered or unexported fields
}
func (*Connector) GetResultChan ¶
func (c *Connector) GetResultChan() chan VerifyResult
GetResultChan 获取识别结果通道
func (*Connector) GetSnapChan ¶ added in v1.2.0
func (c *Connector) GetSnapChan() chan SnapResult
func (*Connector) Initialize ¶
func (*Connector) RemoveDevice ¶
RemoveDevice 删除设备
type RecogniseType ¶
type RecogniseType string
type ResponseData ¶ added in v1.2.0
type SnapResult ¶ added in v1.2.0
type VerifyData ¶ added in v1.2.0
type VerifyData struct { ID string `json:"id"` SN string `json:"SN"` Addr string `json:"Mac_addr"` Time string `json:"time"` // 识别时间 UserID string `json:"employee_number"` Name string `json:"name"` ICNumber string `json:"icNum"` IdentityType string `json:"IdentifyType"` IdentityStatus int `json:"resultStatus"` ImageData string `json:"face_base64"` }
Click to show internal directories.
Click to hide internal directories.