react-native-scanbot-sdk
Version:
Scanbot Document and Barcode Scanner SDK React Native Plugin for Android and iOS
60 lines (56 loc) • 2.18 kB
JavaScript
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.DocumentScannerOutputSettings = void 0;
var _utils = require("../../utils");
var _ParametricFilters = require("../../document/ParametricFilters");
/**
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.
*/
/**
Configuration of the output settings.
*/
class DocumentScannerOutputSettings extends _utils.PartiallyConstructible {
/**
The limit of the number of pages that can be scanned. Default is 0 (no limit).
Default is 0
*/
pagesScanLimit = 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
*/
documentImageSizeLimit = 0;
/**
Determines if the quality analysis for the acknowledgement mode will run on the filtered or the unfiltered image.
Default is UNFILTERED_DOCUMENT
*/
documentAnalysisMode = 'UNFILTERED_DOCUMENT';
/**
Determines the image filter to apply by default.
*/
defaultFilter = null;
/** @param source {@displayType `DeepPartial<DocumentScannerOutputSettings>`} */
constructor(source = {}) {
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 ? _ParametricFilters.ParametricFilter.From(source.defaultFilter) : null;
}
}
}
exports.DocumentScannerOutputSettings = DocumentScannerOutputSettings;
//# sourceMappingURL=DocumentScannerOutputSettings.js.map
;