import { BarcodeDocumentFormat, BarcodeFormat, CheckStandard, Gs1HandlingMode, MSIPlesseyChecksumAlgorithm } from './types'; interface InternalBarcodeDetectionCommonParameters { /** * Accepted barcode formats */ barcodeFormats?: BarcodeFormat[]; /** * An optional array of barcode document formats that act as a detection filter. * By default all supported document formats will be detected. */ acceptedDocumentFormats?: BarcodeDocumentFormat[]; /** * Optional minimum required text length of the detected barcode. * The default is 0 (setting is turned off). * NOTE: This feature works on ITF barcodes only. */ minimumTextLength?: number; /** * Optional maximum required text length of the detected barcode. * The default is 0 (setting is turned off). * NOTE: This feature works on ITF barcodes only. */ maximumTextLength?: number; /** * Optional minimum required quiet zone on the barcode. * Measured in modules (the size of minimal bar on the barcode). * The default is 10. * NOTE: This feature works on ITF barcodes only. */ minimum1DBarcodesQuietZone?: number; /** * With this option enabled, the scanner removes checks digits for UPC, EAN and MSI Plessey codes. * Has no effect if both single and double digit MSI Plessey checksums are enabled. * The default is `false` */ stripCheckDigits?: boolean; /** * The GS1 handling mode. The default value is PARSE. */ gs1HandlingMode?: Gs1HandlingMode; /** * The checksum algorithm for MSI Plessey barcodes. * The default value is Mod10. */ msiPlesseyChecksumAlgorithm?: MSIPlesseyChecksumAlgorithm; } export interface DetectBarcodesOnImageArgs extends InternalBarcodeDetectionCommonParameters { /** * The input image file URI */ imageFileUri: string; } export interface DetectBarcodesOnImagesArgs extends InternalBarcodeDetectionCommonParameters { /** * The input image files URIs */ imageFileUris: string[]; } interface PdfExtractorArguments { /** * The location of the PDF file */ pdfFilePath: string; /** * ( iOS only ) * The quality that each extracted image should have. * This tweaks the compression, affecting the final image file size. * (100: maximum quality, 0: minimum quality) * * Default value is 90 */ quality?: number; /** * ( iOS only ) * Integer scaling factor applied to the PDF media box frame while extracting. * Affects the output image quality. * In most cases the recommended value is 2 or higher. * * Default value is 2. */ scaling?: number; } export interface PerformOCRArguments { imageFileUris: string[]; languages: string[]; options?: { outputFormat?: OCROutputFormat; engineMode?: OCREngineMode; }; } export interface PDFMetadata { author?: string; creator?: string; title?: string; subject?: string; keywords?: string; } export interface CreatePDFArguments { imageFileUris: string[]; options?: { pageSize?: PDFPageSize; pageOrientation?: PDFPageOrientation; metadata?: PDFMetadata; }; } export interface WriteTIFFArguments { imageFileUris: string[]; options?: { oneBitEncoded?: boolean; dpi?: number; compression?: TIFFCompression; }; } export type OCROutputFormat = 'PLAIN_TEXT' | 'PDF_FILE' | 'RESULT_JSON' | 'FULL_OCR_RESULT'; export type OCREngineMode = 'SCANBOT_OCR' | 'TESSERACT'; export type PDFPageSize = 'A3' | 'A4' | 'A5' | 'B4' | 'B5' | 'COMM10' | 'CUSTOM' | 'EXECUTIVE' | 'LEGAL' | 'LETTER' | 'US4x6' | 'US4x8' | 'US5x7'; export type PDFPageOrientation = 'PORTRAIT' | 'LANDSCAPE' | 'AUTO'; export type TIFFCompression = 'NONE' | 'CCITTRLE' | 'CCITTFAX3' | 'CCITT_T4' | 'CCITTFAX4' | 'CCITT_T6' | 'LZW' | 'CCITTRLEW' | 'PACKBITS' | 'DEFLATE' | 'ADOBE_DEFLATE'; export interface ExtractImagesFromPdfArguments extends PdfExtractorArguments { } export interface ExtractPagesFromPdfArguments extends PdfExtractorArguments { } export interface RecognizeCheckOnImageArgs { /** * The input image file URI. */ imageFileUri: string; /** * An optional array of check types that act as a detection filter. * By default all supported check formats will be detected. */ acceptedCheckStandards?: CheckStandard[]; } export {};