目录

class info
com.huawei.hms.mlsdk.card.icr.MLIcrAnalyzerSetting.Factory
Creates an instance of the on-device ID card recognition configurator.

Public Constructor Summary

Constructor name
Factory()Creates an instance of the ID card recognition configurator.

Public Method Summary

Return typeMethod name
MLIcrAnalyzerSettingcreate()
MLIcrAnalyzerSetting.FactorysetCountryCode(String countryCode)
MLIcrAnalyzerSetting.FactorysetSideType(String sideType)

Public Constructors

Method
public Factory()
Creates an instance of the ID card recognition configurator.

Public Methods

Method
public MLIcrAnalyzerSetting create()

Creates an instance of the on-device ID card recognition configurator MLRemoteIcrAnalyzerSetting.

Return

Typedesc
MLIcrAnalyzerSettingReturns an instance of the on-device ID card recognition configurator MLRemoteIcrAnalyzerSetting.
Method

Sample Code

  1. // Creates an ID card recognition configurator.
  2. MLIcrAnalyzerSetting settings = new MLIcrAnalyzerSetting.Factory()
  3.    .setSideType(MLIcrAnalyzerSetting.FRONT)
  4.    .create();

public MLIcrAnalyzerSetting.Factory setCountryCode(String countryCode)

Sets the country code (two-letter code complying with the ISO 3166-1 standard) of the ID card. The default value is CN.

Parameters

Parameter nameParameter desc
countryCodeCountry code (two-letter code complying with the ISO 3166-1 standard) of the ID card. The default value is CN.


Return

Typedesc
MLIcrAnalyzerSetting.FactoryReturns the instance of MLRemoteIcrAnalyzerSetting.Factory.
Method
public MLIcrAnalyzerSetting.Factory setSideType(String sideType)

Sets the front or back side of an ID card.

BACK: back side

FRONT: front side

Parameters

Parameter nameParameter desc
sideTypeFront or back side of an ID card.


Return

Typedesc
MLIcrAnalyzerSetting.FactoryReturns the instance of MLRemoteIcrAnalyzerSetting.Factory.