Table of contents

MRZScannerConfig

MRZScannerConfig is the class that defines the configurations for MRZ scanning. It is set via the input value of MRZScannerActivity.ResultContract

Definition

Assembly: DynamsoftMRZScanner.aar

Namespace: com.dynamsoft.mrzscanner.ui

final class MRZScannerConfig

Methods

Method Description
setLicense Sets the license string.
setTemplateFilePath Sets the local file path for the JSON parameters template file.
setTorchButtonVisible Sets whether to display the torch button when scanning.
setBeepEnabled Sets whether the beep sound is triggered or not when a MRZ is scanned.
setCloseButtonVisible Sets the visibility status of the close button for users to close the scanner page.
setDocumentType Sets the type of document to scan, such as ID cards or passports.
getLicense Returns the license string.
getTemplateFilePath Returns the local path of the settings template file.
isTorchButtonVisible Returns the visibility status of the torch button.
isBeepEnabled Returns the play status of the beep sound when a MRZ is scanned.
isCloseButtonVisible Returns the visibility status of the close button.
getDocumentType Returns the type of document to scan, such as ID cards or passports.
isGuideFrameVisible Returns the visibility status of the guide frame on the display.
setGuideFrameVisible Sets the visibility of the guide frame on the display.

setLicense

Set the license.

void setLicense(String license);

Parameter(s)

license: The license key to be used for initialization.

setTemplateFilePath

Set a path for the SDK to load template file.

void setTemplateFilePath(String templateFilePath);

Parameter(s)

templateFilePath: The path of the JSON template file.

setTorchButtonVisible

Sets whether to display the torch button when scanning. Users can click the torch button to turn on/off the torch.

void setTorchButtonVisible(boolean torchButtonVisible);

Parameter(s)

torchButtonVisible: A boolean value that determines whether to display the torch button.

setBeepEnabled

Sets whether the beep sound is triggered or not when a MRZ is scanned.

void setBeepEnabled(boolean beepEnabled);

Parameter(s)

beepEnabled: A boolean value that determines whether to enable the beep sound.

setCloseButtonVisible

Sets the visibility status of the close button for users to close the scanner page.

void setCloseButtonVisible(boolean closeButtonVisible);

Parameter(s)

closeButtonVisible: A boolean value that determines whether to display the close button.

setDocumentType

Sets the type of document to scan, such as ID cards or passports.

void setDocumentType(EnumDocumentType type);

Parameter(s)

type: The type of document to scan, such as ID cards or passports.

getLicense

Returns the license string.

String getLicense();

Return Value

The license key to be used for initialization.

getTemplateFilePath

Returns the local path of the settings template file.

String getTemplateFilePath();

Return Value

The path of the JSON template file.

isTorchButtonVisible

Returns whether the button is visible.

boolean isTorchButtonVisible();

Return Value

A boolean value that determines whether the torch button is displayed.

isBeepEnabled

Returns whether the beep sound is enabled.

boolean isBeepEnabled();

Return Value

A boolean value that determines whether the beep sound is enabled.

isCloseButtonVisible

Returns whether the close button is visible.

boolean isCloseButtonVisible();

Return Value

A boolean value that determines whether the close button is displayed.

getDocumentType

Returns the type of document to scan, such as ID cards or passports.

EnumDocumentType getDocumentType();

Return Value

The type of document to scan, such as ID cards or passports.

isGuideFrameVisible

Returns the visibility status of the guide frame on the display.

boolean isGuideFrameVisible();

Return Value

A boolean value that determines whether the guide frame is displayed.

setGuideFrameVisible

Set whether to display the guide frame.

void setGuideFrameVisible(boolean guideFrameVisible);

Parameter(s)

guideFrameVisible: A boolean value that determines whether to display the guide frame.

This page is compatible for:

Is this page helpful?

YesYes NoNo

In this article: