CaptureConfig

data class CaptureConfig(val enableCaptureTips: Boolean = true, val allowFlashToggling: Boolean = true, val defaultFlashMode: FlashMode = FlashMode.FLASH_MODE_AUTO, val enableAutoCapture: Boolean = true, val initialAutoCaptureState: Boolean = true, val enableLongReceiptPageToast: Boolean = true, val enableGalleryImport: Boolean = true, @IntRange(from = 1, to = 10) val maxImages: Int = 1, val enableLongCapture: Boolean = true, val enableCrop: Boolean = true, val enableSecureWindow: Boolean = false, val attachLocationData: Boolean = false, val compressForSensibillApi: Boolean = true, val enableCaptureProgressFeedback: Boolean = true, val documentTypeStrings: DocumentTypeStrings = DocumentTypeStrings.defaultReceiptStrings, val documentType: CaptureDocumentType = CaptureDocumentType.RECEIPT) : Serializable

Configuration class to be sent to CaptureStandaloneActivity. This class defines the configurable behaviour for CaptureStandaloneActivity

Constructors

Link copied to clipboard
constructor(enableCaptureTips: Boolean = true, allowFlashToggling: Boolean = true, defaultFlashMode: FlashMode = FlashMode.FLASH_MODE_AUTO, enableAutoCapture: Boolean = true, initialAutoCaptureState: Boolean = true, enableLongReceiptPageToast: Boolean = true, enableGalleryImport: Boolean = true, @IntRange(from = 1, to = 10) maxImages: Int = 1, enableLongCapture: Boolean = true, enableCrop: Boolean = true, enableSecureWindow: Boolean = false, attachLocationData: Boolean = false, compressForSensibillApi: Boolean = true, enableCaptureProgressFeedback: Boolean = true, documentTypeStrings: DocumentTypeStrings = DocumentTypeStrings.defaultReceiptStrings, documentType: CaptureDocumentType = CaptureDocumentType.RECEIPT)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
@SerializedName(value = "allowFlashToggling")
val allowFlashToggling: Boolean = true

Allows the user to toggle the flash mode.

Link copied to clipboard
@SerializedName(value = "attachLocationData")
val attachLocationData: Boolean = false

Enables attaching GPS location data via EXIF to captured images.

Link copied to clipboard
@SerializedName(value = "compressForSensibillApi")
val compressForSensibillApi: Boolean = true

Enables built-in compression for captured images in order to make them compatible with the Sensibill APIs.

Link copied to clipboard
@SerializedName(value = "defaultFlashMode")
val defaultFlashMode: FlashMode

Sets the default flash mode that will be used by the camera

Link copied to clipboard
@SerializedName(value = "documentType")
val documentType: CaptureDocumentType

The CaptureDocumentType for which this configuration is intended. Will be referenced to validate that a valid configuration for the intended document type is being provided when launching capture.

Link copied to clipboard
@SerializedName(value = "documentTypeStrings")
val documentTypeStrings: DocumentTypeStrings

A configuration defining string resources to be used for areas of the capture flow that contain "Document type specific" string resources. This model can be customized to support any required document type. The default value for this model is the "receipt capture" configuration.

Link copied to clipboard
@SerializedName(value = "enableAutoCapture")
val enableAutoCapture: Boolean = true

Enables the auto-capture feature.

Link copied to clipboard
@SerializedName(value = "enableCaptureProgressFeedback")
val enableCaptureProgressFeedback: Boolean = true

Enables capture progress messages that will be displayed when a user is capturing a receipt.

Link copied to clipboard
@SerializedName(value = "enableCaptureTips")
val enableCaptureTips: Boolean = true

Enables the tips feature for capture.

Link copied to clipboard
@SerializedName(value = "enableCrop")
val enableCrop: Boolean = true

Enables the user to manually crop, or adjust the existing cropping on a captured image.

Link copied to clipboard
@SerializedName(value = "enableGalleryImport")
val enableGalleryImport: Boolean = true

Enables the ability for a user to select an image from their device's image gallery.

Link copied to clipboard
@SerializedName(value = "enableLongCapture")
val enableLongCapture: Boolean = true

Enables the long receipt feature.

Link copied to clipboard
@SerializedName(value = "enableLongReceiptPageToast")
val enableLongReceiptPageToast: Boolean = true

Enables a toast message that displays feedback on the capture screen when the long receipt capture process has started. Notifying the user which section is being captured.

Link copied to clipboard
@SerializedName(value = "enableSecureWindow")
val enableSecureWindow: Boolean = false

Enables Android's secure window feature for the capture flow. When enabled, the user will be unable to take screenshots or record the screen.

Link copied to clipboard
@SerializedName(value = "initialAutoCaptureState")
val initialAutoCaptureState: Boolean = true

Sets the initial state of the auto-capture functionality (true represents ON).

Link copied to clipboard
@SerializedName(value = "maxImages")
val maxImages: Int = 1

Determines the maximum number of distinct images that can be captured in a single capture flow. This value must be between 1 and 10 inclusive.