ocr

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 16, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OCR

type OCR struct {
	*context2.Context
}

OCR struct

func NewOCR

func NewOCR(c *context2.Context) *OCR

NewOCR 实例

func (*OCR) BankCard

func (ocr *OCR) BankCard(ctx context.Context, path string) (resBankCard ResBankCard, err error)

BankCard 银行卡OCR识别接口

func (*OCR) BizLicense

func (ocr *OCR) BizLicense(ctx context.Context, path string) (resBizLicense ResBizLicense, err error)

BizLicense 营业执照OCR识别接口

func (*OCR) Common

func (ocr *OCR) Common(ctx context.Context, path string) (resCommon ResCommon, err error)

Common 通用印刷体OCR识别接口

func (*OCR) Driving

func (ocr *OCR) Driving(ctx context.Context, path string) (resDriving ResDriving, err error)

Driving 行驶证OCR识别接口

func (*OCR) DrivingLicense

func (ocr *OCR) DrivingLicense(ctx context.Context, path string) (resDrivingLicense ResDrivingLicense, err error)

DrivingLicense 驾驶证OCR识别接口

func (*OCR) IDCard

func (ocr *OCR) IDCard(ctx context.Context, path string) (resIDCard ResIDCard, err error)

IDCard 身份证OCR识别接口

func (*OCR) PlateNumber

func (ocr *OCR) PlateNumber(ctx context.Context, path string) (resPlateNumber ResPlateNumber, err error)

PlateNumber 车牌OCR识别接口

type ResBankCard

type ResBankCard struct {
	util.CommonError

	Number string `json:"number,omitempty"`
}

ResBankCard 银行卡返回结果

type ResBizLicense

type ResBizLicense struct {
	util.CommonError

	RegisterNumber      string              `json:"reg_num,omitempty"`
	Serial              string              `json:"serial,omitempty"`
	LegalRepresentative string              `json:"legal_representative,omitempty"`
	EnterpriseName      string              `json:"enterprise_name,omitempty"`
	TypeOfOrganization  string              `json:"type_of_organization,omitempty"`
	Address             string              `json:"address,omitempty"`
	TypeOfEnterprise    string              `json:"type_of_enterprise,omitempty"`
	BusinessScope       string              `json:"business_scope,omitempty"`
	RegisteredCapital   string              `json:"registered_capital,omitempty"`
	PaidInCapital       string              `json:"paid_in_capital,omitempty"`
	ValidPeriod         string              `json:"valid_period,omitempty"`
	RegisterDate        string              `json:"registered_date,omitempty"`
	CertPosition        map[string]position `json:"cert_position,omitempty"`
	ImageSize           imageSize           `json:"img_size,omitempty"`
}

ResBizLicense 营业执照返回结果

type ResCommon

type ResCommon struct {
	util.CommonError

	Items     []commonItem `json:"items,omitempty"`
	ImageSize imageSize    `json:"img_size,omitempty"`
}

ResCommon 公共印刷品返回结果

type ResDriving

type ResDriving struct {
	util.CommonError

	PlateNumber       string              `json:"plate_num,omitempty"`
	VehicleType       string              `json:"vehicle_type,omitempty"`
	Owner             string              `json:"owner,omitempty"`
	Address           string              `json:"addr,omitempty"`
	UseCharacter      string              `json:"use_character,omitempty"`
	Model             string              `json:"model,omitempty"`
	Vin               string              `json:"vin,omitempty"`
	EngineNumber      string              `json:"engine_num,omitempty"`
	RegisterDate      string              `json:"register_date,omitempty"`
	IssueDate         string              `json:"issue_date,omitempty"`
	PlateNumberB      string              `json:"plate_num_b,omitempty"`
	Record            string              `json:"record,omitempty"`
	PassengersNumber  string              `json:"passengers_num,omitempty"`
	TotalQuality      string              `json:"total_quality,omitempty"`
	PrepareQuality    string              `json:"prepare_quality,omitempty"`
	OverallSize       string              `json:"overall_size,omitempty"`
	CardPositionFront map[string]position `json:"card_position_front,omitempty"`
	CardPositionBack  map[string]position `json:"card_position_back,omitempty"`
	ImageSize         imageSize           `json:"img_size,omitempty"`
}

ResDriving 行驶证返回结果

type ResDrivingLicense

type ResDrivingLicense struct {
	util.CommonError

	IDNumber     string `json:"id_num,omitempty"`
	Name         string `json:"name,omitempty"`
	Sex          string `json:"sex,omitempty"`
	Nationality  string `json:"nationality,omitempty"`
	Address      string `json:"address,omitempty"`
	Birthday     string `json:"birth_date,omitempty"`
	IssueDate    string `json:"issue_date,omitempty"`
	CarClass     string `json:"car_class,omitempty"`
	ValidFrom    string `json:"valid_from,omitempty"`
	ValidTo      string `json:"valid_to,omitempty"`
	OfficialSeal string `json:"official_seal,omitempty"`
}

ResDrivingLicense 驾驶证返回结果

type ResIDCard

type ResIDCard struct {
	util.CommonError

	Type        string `json:"type,omitempty"`
	Name        string `json:"name,omitempty"`
	ID          string `json:"id,omitempty"`
	Address     string `json:"addr,omitempty"`
	Gender      string `json:"gender,omitempty"`
	Nationality string `json:"nationality,omitempty"`
	ValidDate   string `json:"valid_date,omitempty"`
}

ResIDCard 身份证返回结果

type ResPlateNumber

type ResPlateNumber struct {
	util.CommonError

	Number string `json:"number"`
}

ResPlateNumber 车牌号返回结果

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL