UNPKG

react-native-scanbot-sdk

Version:

Scanbot Document and Barcode Scanner SDK React Native Plugin for Android and iOS

67 lines (57 loc) 2.48 kB
/// Auto-generated with ScanbotSDKCodegenV3. Modifications will be overwritten. /// Generated from rtu-ui-v2/schemas/document/DocumentScannerOutputSettings.yaml import { ParametricFilter } from '../../image_filters/ParametricFilters'; import { DeepPartial, PartiallyConstructible } from '../../utils/utils'; /** Determines if the quality analysis for the acknowledgement mode will run on the filtered or the unfiltered image. - `FILTERED_DOCUMENT`: The quality analysis will run on the filtered document image. - `UNFILTERED_DOCUMENT`: The quality analysis will run on the unfiltered document image. */ export type DocumentAnalysisMode = 'FILTERED_DOCUMENT' | 'UNFILTERED_DOCUMENT'; export const DocumentAnalysisModeValues: DocumentAnalysisMode[] = [ 'FILTERED_DOCUMENT', 'UNFILTERED_DOCUMENT', ]; /** Configuration of the output settings. */ export class DocumentScannerOutputSettings extends PartiallyConstructible { /** The limit of the number of pages that can be scanned. Default is 0 (no limit). Default is 0 */ public pagesScanLimit: number = 0; /** The limit of the size of the cropped document images. If one of the dimensions of the cropped image is larger than the limit, the image is downscaled so that its longer dimension matches the limit. The default is 0 (no limit). Default is 0 */ public documentImageSizeLimit: number = 0; /** Determines if the quality analysis for the acknowledgement mode will run on the filtered or the unfiltered image. Default is UNFILTERED_DOCUMENT */ public documentAnalysisMode: DocumentAnalysisMode = 'UNFILTERED_DOCUMENT'; /** Determines the image filter to apply by default. */ public defaultFilter: ParametricFilter | null = null; /** @param source {@displayType `DeepPartial<DocumentScannerOutputSettings>`} */ public constructor(source: DeepPartial<DocumentScannerOutputSettings> = {}) { super(); if (source.pagesScanLimit !== undefined) { this.pagesScanLimit = source.pagesScanLimit; } if (source.documentImageSizeLimit !== undefined) { this.documentImageSizeLimit = source.documentImageSizeLimit; } if (source.documentAnalysisMode !== undefined) { this.documentAnalysisMode = source.documentAnalysisMode; } if (source.defaultFilter !== undefined) { this.defaultFilter = source.defaultFilter != null ? ParametricFilter.From(source.defaultFilter) : null; } } }