Class GenericDocumentRecognizerJsonConfiguration
-
- All Implemented Interfaces:
-
android.os.Parcelable
public final class GenericDocumentRecognizerJsonConfiguration implements Parcelable
-
-
Field Summary
-
Constructor Summary
Constructors Constructor Description GenericDocumentRecognizerJsonConfiguration(String version, String screen, Boolean flashEnabled, JsonOrientationLockMode orientationLockMode, JsonCameraModule cameraModule, JsonColor topBarBackgroundColor, JsonColor topBarButtonsActiveColor, JsonColor topBarButtonsInactiveColor, JsonColor cameraOverlayColor, JsonColor finderLineColor, Double finderLineWidth, JsonColor fieldsCountTextColor, JsonColor fieldConfidenceHighColor, JsonColor fieldConfidenceModerateColor, JsonColor fieldConfidenceLowColor, JsonColor fieldConfidenceTextColor, JsonColor tipTextColor, JsonColor tipBackgroundColor, JsonColor detailsBackgroundColor, JsonColor detailsPrimaryColor, JsonColor detailsActionColor, String cancelButtonTitle, String clearButtonTitle, String submitButtonTitle, String fieldsCountText, String confidenceValue, String scanBackSideTitle, String scanFrontSideTitle, String startScanningTitle, String scannedEverythingTitle, String enableCameraButtonTitle, String enableCameraExplanationText, String imageTitle, String noDataTitle, List<JsonGenericDocumentType> acceptedDocumentTypes, List<JsonFieldsDisplayConfiguration> fieldsDisplayConfiguration, List<JsonDocumentsDisplayConfiguration> documentsDisplayConfiguration, List<String> excludedFieldTypes, Boolean flashButtonHidden, String flashButtonTitle, Boolean useButtonsAllCaps, Boolean replaceCancelButtonWithIcon, JsonCameraPreviewMode cameraPreviewMode, Boolean touchToFocusEnabled)
-
Method Summary
Modifier and Type Method Description final String
getVersion()
A version of the configuration object final Unit
setVersion(String version)
A version of the configuration object final String
getScreen()
The configuration object should be applied for this screen final Unit
setScreen(String screen)
The configuration object should be applied for this screen final Boolean
getFlashEnabled()
Controls whether the flash should be initially enabled. final Unit
setFlashEnabled(Boolean flashEnabled)
Controls whether the flash should be initially enabled. final JsonOrientationLockMode
getOrientationLockMode()
UI Interface orientation lock mode final Unit
setOrientationLockMode(JsonOrientationLockMode orientationLockMode)
UI Interface orientation lock mode final JsonCameraModule
getCameraModule()
The preferred camera module (default - BACK) final Unit
setCameraModule(JsonCameraModule cameraModule)
The preferred camera module (default - BACK) final JsonColor
getTopBarBackgroundColor()
The background color of the top toolbar. final Unit
setTopBarBackgroundColor(JsonColor topBarBackgroundColor)
The background color of the top toolbar. final JsonColor
getTopBarButtonsActiveColor()
The color of all active toggle buttons in the toolbar. final Unit
setTopBarButtonsActiveColor(JsonColor topBarButtonsActiveColor)
The color of all active toggle buttons in the toolbar. final JsonColor
getTopBarButtonsInactiveColor()
The color of all inactive toggle buttons in the toolbar. final Unit
setTopBarButtonsInactiveColor(JsonColor topBarButtonsInactiveColor)
The color of all inactive toggle buttons in the toolbar. final JsonColor
getCameraOverlayColor()
Background color outside of the finder window. final Unit
setCameraOverlayColor(JsonColor cameraOverlayColor)
Background color outside of the finder window. final JsonColor
getFinderLineColor()
Foreground color of the detection overlay. final Unit
setFinderLineColor(JsonColor finderLineColor)
Foreground color of the detection overlay. final Double
getFinderLineWidth()
Width of finder frame border. final Unit
setFinderLineWidth(Double finderLineWidth)
Width of finder frame border. final JsonColor
getFieldsCountTextColor()
Text color of the fields count label. final Unit
setFieldsCountTextColor(JsonColor fieldsCountTextColor)
Text color of the fields count label. final JsonColor
getFieldConfidenceHighColor()
Color of confidence value label background in details screen, when the field confidence level is high. final Unit
setFieldConfidenceHighColor(JsonColor fieldConfidenceHighColor)
Color of confidence value label background in details screen, when the field confidence level is high. final JsonColor
getFieldConfidenceModerateColor()
Color of confidence value label background in details screen, when the field confidence level is moderate. final Unit
setFieldConfidenceModerateColor(JsonColor fieldConfidenceModerateColor)
Color of confidence value label background in details screen, when the field confidence level is moderate. final JsonColor
getFieldConfidenceLowColor()
Color of confidence value label background in details screen, when the field confidence level is low. final Unit
setFieldConfidenceLowColor(JsonColor fieldConfidenceLowColor)
Color of confidence value label background in details screen, when the field confidence level is low. final JsonColor
getFieldConfidenceTextColor()
Color of confidence value label text in details. final Unit
setFieldConfidenceTextColor(JsonColor fieldConfidenceTextColor)
Color of confidence value label text in details. final JsonColor
getTipTextColor()
Color of tip text on scanning screen. final Unit
setTipTextColor(JsonColor tipTextColor)
Color of tip text on scanning screen. final JsonColor
getTipBackgroundColor()
Color of tip background on scanning screen. final Unit
setTipBackgroundColor(JsonColor tipBackgroundColor)
Color of tip background on scanning screen. final JsonColor
getDetailsBackgroundColor()
The color of bottom sheet final Unit
setDetailsBackgroundColor(JsonColor detailsBackgroundColor)
The color of bottom sheet final JsonColor
getDetailsPrimaryColor()
The color of text elements in bottom sheet final Unit
setDetailsPrimaryColor(JsonColor detailsPrimaryColor)
The color of text elements in bottom sheet final JsonColor
getDetailsActionColor()
The color of Submit button final Unit
setDetailsActionColor(JsonColor detailsActionColor)
The color of Submit button final String
getCancelButtonTitle()
Title of the cancel button. final Unit
setCancelButtonTitle(String cancelButtonTitle)
Title of the cancel button. final String
getClearButtonTitle()
String used for displaying amount of detected fields. final Unit
setClearButtonTitle(String clearButtonTitle)
String used for displaying amount of detected fields. final String
getSubmitButtonTitle()
Text of the button which finishes the flow final Unit
setSubmitButtonTitle(String submitButtonTitle)
Text of the button which finishes the flow final String
getFieldsCountText()
String used for displaying amount of detected fields. final Unit
setFieldsCountText(String fieldsCountText)
String used for displaying amount of detected fields. final String
getConfidenceValue()
String that shows average confidence value of scanned document. final Unit
setConfidenceValue(String confidenceValue)
String that shows average confidence value of scanned document. final String
getScanBackSideTitle()
String that asks user to scan back side of a document. final Unit
setScanBackSideTitle(String scanBackSideTitle)
String that asks user to scan back side of a document. final String
getScanFrontSideTitle()
String that asks user to scan front side of a document. final Unit
setScanFrontSideTitle(String scanFrontSideTitle)
String that asks user to scan front side of a document. final String
getStartScanningTitle()
String that asks user to start scanning a document. final Unit
setStartScanningTitle(String startScanningTitle)
String that asks user to start scanning a document. final String
getScannedEverythingTitle()
String that notifies that both sides of document are scanned. final Unit
setScannedEverythingTitle(String scannedEverythingTitle)
String that notifies that both sides of document are scanned. final String
getEnableCameraButtonTitle()
Title of the button that opens the screen where the user can allow the usage of the camera by the app. final Unit
setEnableCameraButtonTitle(String enableCameraButtonTitle)
Title of the button that opens the screen where the user can allow the usage of the camera by the app. final String
getEnableCameraExplanationText()
Text that will be displayed when the app is not allowed to use the camera, prompting the user to enable the usage of the camera. final Unit
setEnableCameraExplanationText(String enableCameraExplanationText)
Text that will be displayed when the app is not allowed to use the camera, prompting the user to enable the usage of the camera. final String
getImageTitle()
A title to show image content. final Unit
setImageTitle(String imageTitle)
A title to show image content. final String
getNoDataTitle()
String that notifies that nothing was scanned yet. final Unit
setNoDataTitle(String noDataTitle)
String that notifies that nothing was scanned yet. final List<JsonGenericDocumentType>
getAcceptedDocumentTypes()
Accepted document types. final Unit
setAcceptedDocumentTypes(List<JsonGenericDocumentType> acceptedDocumentTypes)
Accepted document types. final List<JsonFieldsDisplayConfiguration>
getFieldsDisplayConfiguration()
Allows to configure the display configuration for fields. final Unit
setFieldsDisplayConfiguration(List<JsonFieldsDisplayConfiguration> fieldsDisplayConfiguration)
Allows to configure the display configuration for fields. final List<JsonDocumentsDisplayConfiguration>
getDocumentsDisplayConfiguration()
Allows to configure the display configuration for documents. final Unit
setDocumentsDisplayConfiguration(List<JsonDocumentsDisplayConfiguration> documentsDisplayConfiguration)
Allows to configure the display configuration for documents. final List<String>
getExcludedFieldTypes()
List of secure fields which should be excluded from scanning process. final Unit
setExcludedFieldTypes(List<String> excludedFieldTypes)
List of secure fields which should be excluded from scanning process. final Boolean
getFlashButtonHidden()
Controls whether the flash toggle button is hidden or not. final Unit
setFlashButtonHidden(Boolean flashButtonHidden)
Controls whether the flash toggle button is hidden or not. final String
getFlashButtonTitle()
Title of the flash toggle button. final Unit
setFlashButtonTitle(String flashButtonTitle)
Title of the flash toggle button. final Boolean
getUseButtonsAllCaps()
Controls whether buttons should use all capitals style, as defined by the Android Material Design. final Unit
setUseButtonsAllCaps(Boolean useButtonsAllCaps)
Controls whether buttons should use all capitals style, as defined by the Android Material Design. final Boolean
getReplaceCancelButtonWithIcon()
If true
, replaces the cancel button in the top bar with a back arrow icon.final Unit
setReplaceCancelButtonWithIcon(Boolean replaceCancelButtonWithIcon)
If true
, replaces the cancel button in the top bar with a back arrow icon.final JsonCameraPreviewMode
getCameraPreviewMode()
Preview mode of the camera. final Unit
setCameraPreviewMode(JsonCameraPreviewMode cameraPreviewMode)
Preview mode of the camera. final Boolean
getTouchToFocusEnabled()
Whether touch-to-focus is enabled on camera preview. final Unit
setTouchToFocusEnabled(Boolean touchToFocusEnabled)
Whether touch-to-focus is enabled on camera preview. -
-
Constructor Detail
-
GenericDocumentRecognizerJsonConfiguration
GenericDocumentRecognizerJsonConfiguration(String version, String screen, Boolean flashEnabled, JsonOrientationLockMode orientationLockMode, JsonCameraModule cameraModule, JsonColor topBarBackgroundColor, JsonColor topBarButtonsActiveColor, JsonColor topBarButtonsInactiveColor, JsonColor cameraOverlayColor, JsonColor finderLineColor, Double finderLineWidth, JsonColor fieldsCountTextColor, JsonColor fieldConfidenceHighColor, JsonColor fieldConfidenceModerateColor, JsonColor fieldConfidenceLowColor, JsonColor fieldConfidenceTextColor, JsonColor tipTextColor, JsonColor tipBackgroundColor, JsonColor detailsBackgroundColor, JsonColor detailsPrimaryColor, JsonColor detailsActionColor, String cancelButtonTitle, String clearButtonTitle, String submitButtonTitle, String fieldsCountText, String confidenceValue, String scanBackSideTitle, String scanFrontSideTitle, String startScanningTitle, String scannedEverythingTitle, String enableCameraButtonTitle, String enableCameraExplanationText, String imageTitle, String noDataTitle, List<JsonGenericDocumentType> acceptedDocumentTypes, List<JsonFieldsDisplayConfiguration> fieldsDisplayConfiguration, List<JsonDocumentsDisplayConfiguration> documentsDisplayConfiguration, List<String> excludedFieldTypes, Boolean flashButtonHidden, String flashButtonTitle, Boolean useButtonsAllCaps, Boolean replaceCancelButtonWithIcon, JsonCameraPreviewMode cameraPreviewMode, Boolean touchToFocusEnabled)
-
-
Method Detail
-
getVersion
final String getVersion()
A version of the configuration object
-
setVersion
final Unit setVersion(String version)
A version of the configuration object
-
setScreen
final Unit setScreen(String screen)
The configuration object should be applied for this screen
-
getFlashEnabled
final Boolean getFlashEnabled()
Controls whether the flash should be initially enabled. The default value is FALSE.
-
setFlashEnabled
final Unit setFlashEnabled(Boolean flashEnabled)
Controls whether the flash should be initially enabled. The default value is FALSE.
-
getOrientationLockMode
final JsonOrientationLockMode getOrientationLockMode()
UI Interface orientation lock mode
-
setOrientationLockMode
final Unit setOrientationLockMode(JsonOrientationLockMode orientationLockMode)
UI Interface orientation lock mode
-
getCameraModule
final JsonCameraModule getCameraModule()
The preferred camera module (default - BACK)
-
setCameraModule
final Unit setCameraModule(JsonCameraModule cameraModule)
The preferred camera module (default - BACK)
-
getTopBarBackgroundColor
final JsonColor getTopBarBackgroundColor()
The background color of the top toolbar.
-
setTopBarBackgroundColor
final Unit setTopBarBackgroundColor(JsonColor topBarBackgroundColor)
The background color of the top toolbar.
-
getTopBarButtonsActiveColor
final JsonColor getTopBarButtonsActiveColor()
The color of all active toggle buttons in the toolbar.
-
setTopBarButtonsActiveColor
final Unit setTopBarButtonsActiveColor(JsonColor topBarButtonsActiveColor)
The color of all active toggle buttons in the toolbar.
-
getTopBarButtonsInactiveColor
final JsonColor getTopBarButtonsInactiveColor()
The color of all inactive toggle buttons in the toolbar.
-
setTopBarButtonsInactiveColor
final Unit setTopBarButtonsInactiveColor(JsonColor topBarButtonsInactiveColor)
The color of all inactive toggle buttons in the toolbar.
-
getCameraOverlayColor
final JsonColor getCameraOverlayColor()
Background color outside of the finder window.
-
setCameraOverlayColor
final Unit setCameraOverlayColor(JsonColor cameraOverlayColor)
Background color outside of the finder window.
-
getFinderLineColor
final JsonColor getFinderLineColor()
Foreground color of the detection overlay.
-
setFinderLineColor
final Unit setFinderLineColor(JsonColor finderLineColor)
Foreground color of the detection overlay.
-
getFinderLineWidth
final Double getFinderLineWidth()
Width of finder frame border. Default is 2.
-
setFinderLineWidth
final Unit setFinderLineWidth(Double finderLineWidth)
Width of finder frame border. Default is 2.
-
getFieldsCountTextColor
final JsonColor getFieldsCountTextColor()
Text color of the fields count label.
-
setFieldsCountTextColor
final Unit setFieldsCountTextColor(JsonColor fieldsCountTextColor)
Text color of the fields count label.
-
getFieldConfidenceHighColor
final JsonColor getFieldConfidenceHighColor()
Color of confidence value label background in details screen, when the field confidence level is high.
-
setFieldConfidenceHighColor
final Unit setFieldConfidenceHighColor(JsonColor fieldConfidenceHighColor)
Color of confidence value label background in details screen, when the field confidence level is high.
-
getFieldConfidenceModerateColor
final JsonColor getFieldConfidenceModerateColor()
Color of confidence value label background in details screen, when the field confidence level is moderate.
-
setFieldConfidenceModerateColor
final Unit setFieldConfidenceModerateColor(JsonColor fieldConfidenceModerateColor)
Color of confidence value label background in details screen, when the field confidence level is moderate.
-
getFieldConfidenceLowColor
final JsonColor getFieldConfidenceLowColor()
Color of confidence value label background in details screen, when the field confidence level is low.
-
setFieldConfidenceLowColor
final Unit setFieldConfidenceLowColor(JsonColor fieldConfidenceLowColor)
Color of confidence value label background in details screen, when the field confidence level is low.
-
getFieldConfidenceTextColor
final JsonColor getFieldConfidenceTextColor()
Color of confidence value label text in details.
-
setFieldConfidenceTextColor
final Unit setFieldConfidenceTextColor(JsonColor fieldConfidenceTextColor)
Color of confidence value label text in details.
-
getTipTextColor
final JsonColor getTipTextColor()
Color of tip text on scanning screen.
-
setTipTextColor
final Unit setTipTextColor(JsonColor tipTextColor)
Color of tip text on scanning screen.
-
getTipBackgroundColor
final JsonColor getTipBackgroundColor()
Color of tip background on scanning screen.
-
setTipBackgroundColor
final Unit setTipBackgroundColor(JsonColor tipBackgroundColor)
Color of tip background on scanning screen.
-
getDetailsBackgroundColor
final JsonColor getDetailsBackgroundColor()
The color of bottom sheet
-
setDetailsBackgroundColor
final Unit setDetailsBackgroundColor(JsonColor detailsBackgroundColor)
The color of bottom sheet
-
getDetailsPrimaryColor
final JsonColor getDetailsPrimaryColor()
The color of text elements in bottom sheet
-
setDetailsPrimaryColor
final Unit setDetailsPrimaryColor(JsonColor detailsPrimaryColor)
The color of text elements in bottom sheet
-
getDetailsActionColor
final JsonColor getDetailsActionColor()
The color of Submit button
-
setDetailsActionColor
final Unit setDetailsActionColor(JsonColor detailsActionColor)
The color of Submit button
-
getCancelButtonTitle
final String getCancelButtonTitle()
Title of the cancel button.
-
setCancelButtonTitle
final Unit setCancelButtonTitle(String cancelButtonTitle)
Title of the cancel button.
-
getClearButtonTitle
final String getClearButtonTitle()
String used for displaying amount of detected fields. Use %d for number formatting symbol.
-
setClearButtonTitle
final Unit setClearButtonTitle(String clearButtonTitle)
String used for displaying amount of detected fields. Use %d for number formatting symbol.
-
getSubmitButtonTitle
final String getSubmitButtonTitle()
Text of the button which finishes the flow
-
setSubmitButtonTitle
final Unit setSubmitButtonTitle(String submitButtonTitle)
Text of the button which finishes the flow
-
getFieldsCountText
final String getFieldsCountText()
String used for displaying amount of detected fields. Use %d for number formatting symbol.
-
setFieldsCountText
final Unit setFieldsCountText(String fieldsCountText)
String used for displaying amount of detected fields. Use %d for number formatting symbol.
-
getConfidenceValue
final String getConfidenceValue()
String that shows average confidence value of scanned document. Use %d as number formatting symbol.
-
setConfidenceValue
final Unit setConfidenceValue(String confidenceValue)
String that shows average confidence value of scanned document. Use %d as number formatting symbol.
-
getScanBackSideTitle
final String getScanBackSideTitle()
String that asks user to scan back side of a document.
-
setScanBackSideTitle
final Unit setScanBackSideTitle(String scanBackSideTitle)
String that asks user to scan back side of a document.
-
getScanFrontSideTitle
final String getScanFrontSideTitle()
String that asks user to scan front side of a document.
-
setScanFrontSideTitle
final Unit setScanFrontSideTitle(String scanFrontSideTitle)
String that asks user to scan front side of a document.
-
getStartScanningTitle
final String getStartScanningTitle()
String that asks user to start scanning a document.
-
setStartScanningTitle
final Unit setStartScanningTitle(String startScanningTitle)
String that asks user to start scanning a document.
-
getScannedEverythingTitle
final String getScannedEverythingTitle()
String that notifies that both sides of document are scanned.
-
setScannedEverythingTitle
final Unit setScannedEverythingTitle(String scannedEverythingTitle)
String that notifies that both sides of document are scanned.
-
getEnableCameraButtonTitle
final String getEnableCameraButtonTitle()
Title of the button that opens the screen where the user can allow the usage of the camera by the app.
-
setEnableCameraButtonTitle
final Unit setEnableCameraButtonTitle(String enableCameraButtonTitle)
Title of the button that opens the screen where the user can allow the usage of the camera by the app.
-
getEnableCameraExplanationText
final String getEnableCameraExplanationText()
Text that will be displayed when the app is not allowed to use the camera, prompting the user to enable the usage of the camera.
-
setEnableCameraExplanationText
final Unit setEnableCameraExplanationText(String enableCameraExplanationText)
Text that will be displayed when the app is not allowed to use the camera, prompting the user to enable the usage of the camera.
-
getImageTitle
final String getImageTitle()
A title to show image content. Android only.
-
setImageTitle
final Unit setImageTitle(String imageTitle)
A title to show image content. Android only.
-
getNoDataTitle
final String getNoDataTitle()
String that notifies that nothing was scanned yet.
-
setNoDataTitle
final Unit setNoDataTitle(String noDataTitle)
String that notifies that nothing was scanned yet.
-
getAcceptedDocumentTypes
final List<JsonGenericDocumentType> getAcceptedDocumentTypes()
Accepted document types. All other document types will be ignored. By default - All types
-
setAcceptedDocumentTypes
final Unit setAcceptedDocumentTypes(List<JsonGenericDocumentType> acceptedDocumentTypes)
Accepted document types. All other document types will be ignored. By default - All types
-
getFieldsDisplayConfiguration
final List<JsonFieldsDisplayConfiguration> getFieldsDisplayConfiguration()
Allows to configure the display configuration for fields.
-
setFieldsDisplayConfiguration
final Unit setFieldsDisplayConfiguration(List<JsonFieldsDisplayConfiguration> fieldsDisplayConfiguration)
Allows to configure the display configuration for fields.
-
getDocumentsDisplayConfiguration
final List<JsonDocumentsDisplayConfiguration> getDocumentsDisplayConfiguration()
Allows to configure the display configuration for documents.
-
setDocumentsDisplayConfiguration
final Unit setDocumentsDisplayConfiguration(List<JsonDocumentsDisplayConfiguration> documentsDisplayConfiguration)
Allows to configure the display configuration for documents.
-
getExcludedFieldTypes
final List<String> getExcludedFieldTypes()
List of secure fields which should be excluded from scanning process. All other fields will be scanned as usual. Field should be set ONLY as normalized field name. Example - DePassport.BirthDate or DePassport.Birthplace
-
setExcludedFieldTypes
final Unit setExcludedFieldTypes(List<String> excludedFieldTypes)
List of secure fields which should be excluded from scanning process. All other fields will be scanned as usual. Field should be set ONLY as normalized field name. Example - DePassport.BirthDate or DePassport.Birthplace
-
getFlashButtonHidden
final Boolean getFlashButtonHidden()
Controls whether the flash toggle button is hidden or not.
-
setFlashButtonHidden
final Unit setFlashButtonHidden(Boolean flashButtonHidden)
Controls whether the flash toggle button is hidden or not.
-
getFlashButtonTitle
final String getFlashButtonTitle()
Title of the flash toggle button.
-
setFlashButtonTitle
final Unit setFlashButtonTitle(String flashButtonTitle)
Title of the flash toggle button.
-
getUseButtonsAllCaps
final Boolean getUseButtonsAllCaps()
Controls whether buttons should use all capitals style, as defined by the Android Material Design. Defaults to TRUE. Android only.
-
setUseButtonsAllCaps
final Unit setUseButtonsAllCaps(Boolean useButtonsAllCaps)
Controls whether buttons should use all capitals style, as defined by the Android Material Design. Defaults to TRUE. Android only.
-
getReplaceCancelButtonWithIcon
final Boolean getReplaceCancelButtonWithIcon()
If
true
, replaces the cancel button in the top bar with a back arrow icon. The default value is FALSE. Android only.
-
setReplaceCancelButtonWithIcon
final Unit setReplaceCancelButtonWithIcon(Boolean replaceCancelButtonWithIcon)
If
true
, replaces the cancel button in the top bar with a back arrow icon. The default value is FALSE. Android only.
-
getCameraPreviewMode
final JsonCameraPreviewMode getCameraPreviewMode()
Preview mode of the camera. FILL_IN or FIT_IN. Default is FILL_IN. Android only
-
setCameraPreviewMode
final Unit setCameraPreviewMode(JsonCameraPreviewMode cameraPreviewMode)
Preview mode of the camera. FILL_IN or FIT_IN. Default is FILL_IN. Android only
-
getTouchToFocusEnabled
final Boolean getTouchToFocusEnabled()
Whether touch-to-focus is enabled on camera preview. Enabled by default. Android only.
-
setTouchToFocusEnabled
final Unit setTouchToFocusEnabled(Boolean touchToFocusEnabled)
Whether touch-to-focus is enabled on camera preview. Enabled by default. Android only.
-
-
-
-