Class MrzScannerJsonConfiguration
-
- All Implemented Interfaces:
-
android.os.Parcelable
public final class MrzScannerJsonConfiguration implements Parcelable
-
-
Field Summary
Fields Modifier and Type Field Description private String
version
private String
screen
private JsonCameraModule
cameraModule
private JsonColor
cameraOverlayColor
private String
cancelButtonTitle
private String
enableCameraButtonTitle
private String
enableCameraExplanationText
private JsonColor
finderLineColor
private Double
finderLineWidth
private String
finderTextHint
private JsonColor
finderTextHintColor
private JsonAspectRatio
finderAspectRatio
private Boolean
flashEnabled
private JsonOrientationLockMode
orientationLockMode
private Boolean
successBeepEnabled
private JsonColor
topBarBackgroundColor
private JsonColor
topBarButtonsActiveColor
private JsonColor
topBarButtonsInactiveColor
private Boolean
useButtonsAllCaps
private Boolean
replaceCancelButtonWithIcon
private JsonCameraPreviewMode
cameraPreviewMode
private Boolean
touchToFocusEnabled
-
Constructor Summary
Constructors Constructor Description MrzScannerJsonConfiguration(String version, String screen, JsonCameraModule cameraModule, JsonColor cameraOverlayColor, String cancelButtonTitle, String enableCameraButtonTitle, String enableCameraExplanationText, JsonColor finderLineColor, Double finderLineWidth, String finderTextHint, JsonColor finderTextHintColor, JsonAspectRatio finderAspectRatio, Boolean flashEnabled, JsonOrientationLockMode orientationLockMode, Boolean successBeepEnabled, JsonColor topBarBackgroundColor, JsonColor topBarButtonsActiveColor, JsonColor topBarButtonsInactiveColor, Boolean useButtonsAllCaps, Boolean replaceCancelButtonWithIcon, JsonCameraPreviewMode cameraPreviewMode, Boolean touchToFocusEnabled)
-
Method Summary
Modifier and Type Method Description final String
getVersion()
Version of the configuration object. final Unit
setVersion(String version)
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 JsonCameraModule
getCameraModule()
Preferred camera module (Default: BACK). final Unit
setCameraModule(JsonCameraModule cameraModule)
Preferred camera module (Default: BACK). final JsonColor
getCameraOverlayColor()
Background color outside of the finder window. final Unit
setCameraOverlayColor(JsonColor cameraOverlayColor)
Background color outside of the finder window. final String
getCancelButtonTitle()
Title of the cancel button. final Unit
setCancelButtonTitle(String cancelButtonTitle)
Title of the cancel button. final String
getEnableCameraButtonTitle()
Title of the button that opens the screen where the user can allow the app to use the camera. final Unit
setEnableCameraButtonTitle(String enableCameraButtonTitle)
Title of the button that opens the screen where the user can allow the app to use the camera. 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 JsonColor
getFinderLineColor()
Foreground color of the detection overlay. final Unit
setFinderLineColor(JsonColor finderLineColor)
Foreground color of the detection overlay. final Double
getFinderLineWidth()
Width of the finder frame border. final Unit
setFinderLineWidth(Double finderLineWidth)
Width of the finder frame border. final String
getFinderTextHint()
String being displayed as a description. final Unit
setFinderTextHint(String finderTextHint)
String being displayed as a description. final JsonColor
getFinderTextHintColor()
Foreground color of the description label. final Unit
setFinderTextHintColor(JsonColor finderTextHintColor)
Foreground color of the description label. final JsonAspectRatio
getFinderAspectRatio()
Aspect ratio of the finder frame (width to height), which is used to build the actual finder frame. final Unit
setFinderAspectRatio(JsonAspectRatio finderAspectRatio)
Aspect ratio of the finder frame (width to height), which is used to build the actual finder frame. final Boolean
getFlashEnabled()
Whether the flash should be initially enabled. final Unit
setFlashEnabled(Boolean flashEnabled)
Whether the flash should be initially enabled. final JsonOrientationLockMode
getOrientationLockMode()
Lock mode for the UI's orientation. final Unit
setOrientationLockMode(JsonOrientationLockMode orientationLockMode)
Lock mode for the UI's orientation. final Boolean
getSuccessBeepEnabled()
Whether to play a beep sound after a successful detection. final Unit
setSuccessBeepEnabled(Boolean successBeepEnabled)
Whether to play a beep sound after a successful detection. final JsonColor
getTopBarBackgroundColor()
Background color of the top toolbar. final Unit
setTopBarBackgroundColor(JsonColor topBarBackgroundColor)
Background color of the top toolbar. final JsonColor
getTopBarButtonsActiveColor()
Color of all active toggle buttons in the toolbar. final Unit
setTopBarButtonsActiveColor(JsonColor topBarButtonsActiveColor)
Color of all active toggle buttons in the toolbar. final JsonColor
getTopBarButtonsInactiveColor()
Color of all inactive toggle buttons in the toolbar. final Unit
setTopBarButtonsInactiveColor(JsonColor topBarButtonsInactiveColor)
Color of all inactive toggle buttons in the toolbar. final Boolean
getUseButtonsAllCaps()
Whether buttons should use all-capitals style, as defined by the Android Material Design. final Unit
setUseButtonsAllCaps(Boolean useButtonsAllCaps)
Whether buttons should use all-capitals style, as defined by the Android Material Design. final Boolean
getReplaceCancelButtonWithIcon()
Whether to replace the cancel button in the top bar with a back arrow icon. final Unit
setReplaceCancelButtonWithIcon(Boolean replaceCancelButtonWithIcon)
Whether to replace 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 the camera preview. final Unit
setTouchToFocusEnabled(Boolean touchToFocusEnabled)
Whether touch-to-focus is enabled on the camera preview. -
-
Constructor Detail
-
MrzScannerJsonConfiguration
MrzScannerJsonConfiguration(String version, String screen, JsonCameraModule cameraModule, JsonColor cameraOverlayColor, String cancelButtonTitle, String enableCameraButtonTitle, String enableCameraExplanationText, JsonColor finderLineColor, Double finderLineWidth, String finderTextHint, JsonColor finderTextHintColor, JsonAspectRatio finderAspectRatio, Boolean flashEnabled, JsonOrientationLockMode orientationLockMode, Boolean successBeepEnabled, JsonColor topBarBackgroundColor, JsonColor topBarButtonsActiveColor, JsonColor topBarButtonsInactiveColor, Boolean useButtonsAllCaps, Boolean replaceCancelButtonWithIcon, JsonCameraPreviewMode cameraPreviewMode, Boolean touchToFocusEnabled)
-
-
Method Detail
-
getVersion
final String getVersion()
Version of the configuration object.
-
setVersion
final Unit setVersion(String version)
Version of the configuration object.
-
setScreen
final Unit setScreen(String screen)
The configuration object should be applied for this screen.
-
getCameraModule
final JsonCameraModule getCameraModule()
Preferred camera module (Default: BACK).
-
setCameraModule
final Unit setCameraModule(JsonCameraModule cameraModule)
Preferred camera module (Default: BACK).
-
getCameraOverlayColor
final JsonColor getCameraOverlayColor()
Background color outside of the finder window.
-
setCameraOverlayColor
final Unit setCameraOverlayColor(JsonColor cameraOverlayColor)
Background color outside of the finder window.
-
getCancelButtonTitle
final String getCancelButtonTitle()
Title of the cancel button.
-
setCancelButtonTitle
final Unit setCancelButtonTitle(String cancelButtonTitle)
Title of the cancel button.
-
getEnableCameraButtonTitle
final String getEnableCameraButtonTitle()
Title of the button that opens the screen where the user can allow the app to use the camera.
-
setEnableCameraButtonTitle
final Unit setEnableCameraButtonTitle(String enableCameraButtonTitle)
Title of the button that opens the screen where the user can allow the app to use the camera.
-
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.
-
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 the finder frame border. Default is 2.
-
setFinderLineWidth
final Unit setFinderLineWidth(Double finderLineWidth)
Width of the finder frame border. Default is 2.
-
getFinderTextHint
final String getFinderTextHint()
String being displayed as a description.
-
setFinderTextHint
final Unit setFinderTextHint(String finderTextHint)
String being displayed as a description.
-
getFinderTextHintColor
final JsonColor getFinderTextHintColor()
Foreground color of the description label.
-
setFinderTextHintColor
final Unit setFinderTextHintColor(JsonColor finderTextHintColor)
Foreground color of the description label.
-
getFinderAspectRatio
final JsonAspectRatio getFinderAspectRatio()
Aspect ratio of the finder frame (width to height), which is used to build the actual finder frame. Default is 7, which is good for standard machine readable zones.
-
setFinderAspectRatio
final Unit setFinderAspectRatio(JsonAspectRatio finderAspectRatio)
Aspect ratio of the finder frame (width to height), which is used to build the actual finder frame. Default is 7, which is good for standard machine readable zones.
-
getFlashEnabled
final Boolean getFlashEnabled()
Whether the flash should be initially enabled. The default value is FALSE.
-
setFlashEnabled
final Unit setFlashEnabled(Boolean flashEnabled)
Whether the flash should be initially enabled. The default value is FALSE.
-
getOrientationLockMode
final JsonOrientationLockMode getOrientationLockMode()
Lock mode for the UI's orientation.
-
setOrientationLockMode
final Unit setOrientationLockMode(JsonOrientationLockMode orientationLockMode)
Lock mode for the UI's orientation.
-
getSuccessBeepEnabled
final Boolean getSuccessBeepEnabled()
Whether to play a beep sound after a successful detection. Default value is TRUE.
-
setSuccessBeepEnabled
final Unit setSuccessBeepEnabled(Boolean successBeepEnabled)
Whether to play a beep sound after a successful detection. Default value is TRUE.
-
getTopBarBackgroundColor
final JsonColor getTopBarBackgroundColor()
Background color of the top toolbar.
-
setTopBarBackgroundColor
final Unit setTopBarBackgroundColor(JsonColor topBarBackgroundColor)
Background color of the top toolbar.
-
getTopBarButtonsActiveColor
final JsonColor getTopBarButtonsActiveColor()
Color of all active toggle buttons in the toolbar.
-
setTopBarButtonsActiveColor
final Unit setTopBarButtonsActiveColor(JsonColor topBarButtonsActiveColor)
Color of all active toggle buttons in the toolbar.
-
getTopBarButtonsInactiveColor
final JsonColor getTopBarButtonsInactiveColor()
Color of all inactive toggle buttons in the toolbar.
-
setTopBarButtonsInactiveColor
final Unit setTopBarButtonsInactiveColor(JsonColor topBarButtonsInactiveColor)
Color of all inactive toggle buttons in the toolbar.
-
getUseButtonsAllCaps
final Boolean getUseButtonsAllCaps()
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)
Whether buttons should use all-capitals style, as defined by the Android Material Design. Defaults to TRUE. Android only.
-
getReplaceCancelButtonWithIcon
final Boolean getReplaceCancelButtonWithIcon()
Whether to replace the cancel button in the top bar with a back arrow icon. Default is FALSE. Android only.
-
setReplaceCancelButtonWithIcon
final Unit setReplaceCancelButtonWithIcon(Boolean replaceCancelButtonWithIcon)
Whether to replace the cancel button in the top bar with a back arrow icon. Default 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 the camera preview. Enabled by default. Android only.
-
setTouchToFocusEnabled
final Unit setTouchToFocusEnabled(Boolean touchToFocusEnabled)
Whether touch-to-focus is enabled on the camera preview. Enabled by default. Android only.
-
-
-
-