1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- import 'dart:ui';
- class IDCardRecognition {
- Future<bool> initiate(ModelDataInformation modelDataInfo) async {
- return true;
- }
- Future<IDCardRecogResultInfo?> evaluateOneImage(Image image) async {
- try {
- return null;
- } catch (e) {
- return null;
- }
- }
- void writeDatatoFile() {}
- String _addLeadingZero(int value) {
- return value.toString().padLeft(2, '0');
- }
- void release() {}
- }
- class ModelDataInformation {
- final String ocrv4DetInfer;
- final String ocrv4RecInfer;
- final String ppocrKeysV1;
- final String ppocrMobileClsTrain;
- ModelDataInformation({
- required this.ocrv4DetInfer,
- required this.ocrv4RecInfer,
- required this.ppocrKeysV1,
- required this.ppocrMobileClsTrain,
- });
- }
- // 定义 IDCardRecogResult 结构体
- class IDCardRecogResultInfo {
- int numerStatus;
- String? name;
- String? idNumber;
- String? gender;
- String? nation;
- String? birthdate;
- String? address;
- IDCardRecogResultInfo({
- this.numerStatus = 0,
- this.name,
- this.idNumber,
- this.gender,
- this.nation,
- this.birthdate,
- this.address,
- });
- }
|