Class ProcessParam


  • public class ProcessParam
    extends java.lang.Object
    structure, used to configure the processing workflow will be checked against CORE capabilities
    See Also:
    Processing parameters
    • Field Summary

      Fields 
      Modifier and Type Field Description
      java.lang.Boolean alreadyCropped
      This option can be set to true if you know for sure that the image you provide contains already cropped document by its edges.
      AuthenticityParams authenticityParams  
      BackendProcessingConfig backendProcessingConfig
      Set up the backend processing service parameters,
      java.lang.Integer barcodeParserType
      Use the following property to set up the barcode parser type which should be used during the recognition.
      java.lang.String captureButtonScenario
      quickly set proper processing parameters when processing single image captured one of Scenario members
      java.lang.Boolean checkHologram
      Deprecated.
      java.lang.Boolean checkRequiredTextFields
      When enabled, each field in template will be checked for value presence and if the field is marked as required, but has no value, it will have "error" in validity status.
      java.lang.Integer convertCase
      This option allows output text case transformation.
      JSONObject customParams
      This option allows to pass custom processing parameters that can be implemented in future without changing API.
      java.lang.String dateFormat
      format string of displayed dates in the results
      java.lang.Boolean debugSaveCroppedImages
      if set, cropped images of the document will be saved (in case of reading problems)
      java.lang.Boolean debugSaveImages
      if set, input images will be saved (in case of reading problems)
      java.lang.Boolean debugSaveLogs
      if set, deep logs will be saved (in case of reading problems)
      java.lang.Boolean debugSaveRFIDSession  
      java.lang.Boolean depersonalizeLog
      When enabled all personal data will be forcibly removed from the logs.
      java.lang.Boolean disableFocusingCheck
      if set, images will not be checked
      java.lang.Boolean disablePerforationOCR
      When enabled, OCR of perforated fields in the document template will not be performed.
      java.lang.String[] doBarcodes
      Set the types of barcodes to process.
      java.lang.Double documentAreaMin
      Specifies minimal area of the image that document should cover to be treated as candidate when locating.
      int[] documentGroupFilter
      List of specific eligible document types from DocumentType enum to recognize from.
      int[] documentIDList
      List of the document ID's to process.
      ElementPosition documentPosition  
      java.lang.Boolean doDetectCan
      Enable the CAN (Card Access Number) detection when using scenarios with document location and MRZ reading, such as the MrzAndLocate scenario
      java.lang.Boolean doFlipYAxis  
      java.lang.Boolean doublePageSpread
      This option can be set to true if the image you provide contains double page spread of the passport and you want to process both pages in one go.
      FaceApiParams faceApiParams
      Set up the Face SDK service parameters,
      FaceMetaData[] faceMetaData  
      java.lang.Boolean fastDocDetect
      Deprecated.
      int[] fieldTypesFilter
      List of field types eVisualFieldType.VisualFieldTypes to extract.
      java.lang.Integer forceDocFormat
      Force use of specified document format when locating and recognizing document to reduce the number of candidates.
      java.lang.Integer forceDocID
      Force use of specific template ID and skip document type identification step.
      java.lang.Boolean forceReadMrzBeforeLocate
      This option can be set to true to make sure that in series processing MRZ is located fully inside the result document image, if present on the document.
      java.lang.Boolean generateDoublePageSpreadImage
      When enabled together with "doublePageSpread" and there is a passport with two pages spread in the image, pages will be cropped, straightened and aligned together, as if the document was captured on a flatbed scanner.
      java.lang.Boolean generateDTCVC
      This parameter is used to generate Dtc
      java.lang.Boolean generateNumericCodes
      This parameter is used to generate numeric representation for issuing state and nationality codes
      java.lang.Integer imageDpiOutMax
      This option controls maximum resolution in dpi of output images.
      java.lang.Integer imageOutputMaxHeight
      This option controls maximum height in pixels of output images.
      java.lang.Integer imageOutputMaxWidth
      This option controls maximum width in pixels of output images.
      ImageQA imageQA
      java.lang.Boolean integralImage
      Build an integral image taking into account the quality of fixation of each of the individual images
      int[] lcidFilter
      The list of LCID types to recognize.
      int[] lcidIgnoreFilter
      The list of LCID types to ignore during the recognition.
      LogLevel logLevel
      Sets the level of logs detalization when used together with setLogs(Boolean) parameter.
      java.lang.Boolean manualCrop
      if set, manual setting of document's bounds will be enabled
      java.lang.Boolean matchTextFieldMask
      When disabled, text field OCR will be done as is and then the recognized value will be matched to the field mask for validity.
      java.lang.Integer measureSystem
      use one of RGLMeasureSystem values
      java.lang.Integer minDPI
      the minimum acceptable DPI value
      java.lang.Integer minimalHolderAge
      This options allows specifying the minimal age in years of the document holder for the document to be considered valid.
      java.lang.Integer mrzDetectMode
      Make better MRZ detection on complex noisy backgrounds, like BW photocopy of some documents.
      java.lang.String[] mrzFormatsFilter
      This option allows limiting MRZ formats to be recognized by specifying them in array.
      java.lang.Boolean multiDocOnImage
      This option allows locating and cropping multiple documents from one image if enabled.
      java.lang.Boolean multipageProcessing
      if set,
      java.lang.Boolean noGraphics
      When enabled no graphic fields will be cropped from document image.
      java.lang.Boolean parseBarcodes
      When set to false, the Barcode code parsing will be skipped and the raw information from the code will be returned instead.
      java.lang.Integer perspectiveAngle
      the maximum value of the deviation of the corners of the document from the 90 degrees value
      java.lang.Integer processAuth
      Accepts sum of eRPRM_Authenticity elements
      java.lang.Boolean respectImageQuality
      Deprecated.
      int[] resultTypeOutput
      Types of results to return in response.
      java.lang.Boolean returnCroppedBarcode
      When enabled, returns cropped barcode images for unknown documents
      java.lang.Boolean returnUncroppedImage
      This option allows returning input images in output if enabled.
      RFIDParams rfidParams  
      java.lang.String scenario
      quickly set proper processing parameters, one of Scenario members
      java.lang.Boolean selectLongestNames
      Select the longest value from the different value sources and write it to the value field if comparison is done successfully.
      java.lang.String sessionLogFolder
      The path to the folder of the current session.
      java.lang.Integer shiftExpiryDate
      This option allows shifting the date of expiry into the future or past for number of months specified.
      java.lang.Boolean shouldReturnPackageForReprocess
      When set to `true`, the DocumentReaderResults.rawResult property of the DocumentReaderResults will contain the encrypted containers of scanning results that may be used for later reprocessing.
      java.lang.Boolean splitNames
      When enabled, the Surname and GivenNames field will be divided into ft_First_Name, ft_Second_Name, ft_Third_Name, ft_Fourth_Name, ft_Last_Name fields.
      java.lang.Boolean strictBarcodeDigitalSignatureCheck
      If the certificates required for performing the Digital signature check are missing, this parameter if enabled will make the Barcode format check failed
      java.lang.Boolean strictImageQuality
      When enabled, the image quality check status affects the document optical and overall status.
      java.lang.Double timeout
      The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result.
      java.lang.Double timeoutFromFirstDetect
      The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result.
      java.lang.Double timeoutFromFirstDocType
      The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result.
      java.lang.Double timeoutLiveness
      Start the countdown from the moment the document liveness authenticity check is started (in seconds)
      java.lang.Boolean updateOCRValidityByGlare
      When enabled, fail OCR field validity, if there is a glare over the text field on the image.
      java.lang.Boolean useAuthenticityCheck  
      java.lang.Boolean useFaceApi
      Use this property to set up the Face API integration.
      java.lang.Boolean uvTorchEnabled
      true when torch is connected and enabled by user
    • Constructor Summary

      Constructors 
      Constructor Description
      ProcessParam()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      ProcessParam fromJson​(java.lang.String json)
      Converts properly formatted JSON string to the params object instance
      java.lang.String getCoreJson()
      Method is returned process params to core for each frame
      java.lang.String getRfidCoreJson()
      Method is returned process params to core during rfid reading
      java.lang.String getScenario()
      Returns the current document processing scenario.
      java.lang.Boolean isLogEnable()
      Indicates if logging to logcat console is enabled
      boolean isManualCropAvailable()
      Flag, indicates if manual document boundaries setting is available
      void setLogs​(java.lang.Boolean logs)
      Enables logging to the logcat console
      void setScenario​(java.lang.String scenario)
      Use this method to set the document processing scenario.
      java.lang.String toJson()
      Method converts object to string in json format
      JSONObject toJSONObject()
      Method converts params object to JSONObject instance
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • multipageProcessing

        public java.lang.Boolean multipageProcessing
        if set,
      • dateFormat

        public java.lang.String dateFormat
        format string of displayed dates in the results
      • debugSaveImages

        public java.lang.Boolean debugSaveImages
        if set, input images will be saved (in case of reading problems)
      • debugSaveLogs

        public java.lang.Boolean debugSaveLogs
        if set, deep logs will be saved (in case of reading problems)
      • scenario

        public java.lang.String scenario
        quickly set proper processing parameters, one of Scenario members
      • uvTorchEnabled

        public java.lang.Boolean uvTorchEnabled
        true when torch is connected and enabled by user
      • documentIDList

        public int[] documentIDList
        List of the document ID's to process. All documents will be processed, if empty.
      • debugSaveCroppedImages

        public java.lang.Boolean debugSaveCroppedImages
        if set, cropped images of the document will be saved (in case of reading problems)
      • sessionLogFolder

        public java.lang.String sessionLogFolder
        The path to the folder of the current session. Before using this, save logs. Each new session provides a different path
      • disableFocusingCheck

        public java.lang.Boolean disableFocusingCheck
        if set, images will not be checked
      • captureButtonScenario

        public java.lang.String captureButtonScenario
        quickly set proper processing parameters when processing single image captured one of Scenario members
      • measureSystem

        public java.lang.Integer measureSystem
        use one of RGLMeasureSystem values
      • returnUncroppedImage

        public java.lang.Boolean returnUncroppedImage
        This option allows returning input images in output if enabled.
      • returnCroppedBarcode

        public java.lang.Boolean returnCroppedBarcode
        When enabled, returns cropped barcode images for unknown documents
      • faceMetaData

        public FaceMetaData[] faceMetaData
      • customParams

        public JSONObject customParams
        This option allows to pass custom processing parameters that can be implemented in future without changing API.
      • debugSaveRFIDSession

        public java.lang.Boolean debugSaveRFIDSession
      • doublePageSpread

        public java.lang.Boolean doublePageSpread
        This option can be set to true if the image you provide contains double page spread of the passport and you want to process both pages in one go. It makes sense to use it for documents that have meaningful information on both pages, like Russian domestic passport, or some others.
      • manualCrop

        public java.lang.Boolean manualCrop
        if set, manual setting of document's bounds will be enabled
      • barcodeParserType

        public java.lang.Integer barcodeParserType
        Use the following property to set up the barcode parser type which should be used during the recognition.
      • integralImage

        public java.lang.Boolean integralImage
        Build an integral image taking into account the quality of fixation of each of the individual images
      • minDPI

        public java.lang.Integer minDPI
        the minimum acceptable DPI value
      • perspectiveAngle

        public java.lang.Integer perspectiveAngle
        the maximum value of the deviation of the corners of the document from the 90 degrees value
      • timeout

        public java.lang.Double timeout
        The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result. The countdown will start from the moment the scenario starts
      • timeoutFromFirstDetect

        public java.lang.Double timeoutFromFirstDetect
        The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result. The countdown will start from the moment the document is detected
      • timeoutFromFirstDocType

        public java.lang.Double timeoutFromFirstDocType
        The time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result. The countdown will start from the moment the document type is recognized
      • timeoutLiveness

        public java.lang.Double timeoutLiveness
        Start the countdown from the moment the document liveness authenticity check is started (in seconds)
      • checkHologram

        @Deprecated
        public java.lang.Boolean checkHologram
        Deprecated.
        Define whether to check the holograms Use authenticityParams instead.
      • checkRequiredTextFields

        public java.lang.Boolean checkRequiredTextFields
        When enabled, each field in template will be checked for value presence and if the field is marked as required, but has no value, it will have "error" in validity status.
      • depersonalizeLog

        public java.lang.Boolean depersonalizeLog
        When enabled all personal data will be forcibly removed from the logs.
      • resultTypeOutput

        public int[] resultTypeOutput
        Types of results to return in response. See 'Result' enum for available options
      • generateDoublePageSpreadImage

        public java.lang.Boolean generateDoublePageSpreadImage
        When enabled together with "doublePageSpread" and there is a passport with two pages spread in the image, pages will be cropped, straightened and aligned together, as if the document was captured on a flatbed scanner.
      • imageDpiOutMax

        public java.lang.Integer imageDpiOutMax
        This option controls maximum resolution in dpi of output images. Resolution will remain original in case 0 is supplied. By default is set to return images in response with resolution not greater than 300 dpi.
      • imageOutputMaxHeight

        public java.lang.Integer imageOutputMaxHeight
        This option controls maximum height in pixels of output images.
      • imageOutputMaxWidth

        public java.lang.Integer imageOutputMaxWidth
        This option controls maximum width in pixels of output images.
      • alreadyCropped

        public java.lang.Boolean alreadyCropped
        This option can be set to true if you know for sure that the image you provide contains already cropped document by its edges. This was designed to process on the server side images captured and cropped on mobile.
      • forceDocID

        public java.lang.Integer forceDocID
        Force use of specific template ID and skip document type identification step.
      • matchTextFieldMask

        public java.lang.Boolean matchTextFieldMask
        When disabled, text field OCR will be done as is and then the recognized value will be matched to the field mask for validity. If enabled, we are trying to read a field value with maximum efforts to match the mask and provide a correctly formatted value, making assumptions based on the provided field mask in the template.
      • fastDocDetect

        @Deprecated
        public java.lang.Boolean fastDocDetect
        Deprecated.
        When enabled, shorten the list of candidates to process during document detection in a single image process mode. Reduces processing time for specific backgrounds.
      • updateOCRValidityByGlare

        public java.lang.Boolean updateOCRValidityByGlare
        When enabled, fail OCR field validity, if there is a glare over the text field on the image.
      • forceDocFormat

        public java.lang.Integer forceDocFormat
        Force use of specified document format when locating and recognizing document to reduce the number of candidates.
      • noGraphics

        public java.lang.Boolean noGraphics
        When enabled no graphic fields will be cropped from document image.
      • documentAreaMin

        public java.lang.Double documentAreaMin
        Specifies minimal area of the image that document should cover to be treated as candidate when locating. Value should be in range from 0 to 1, where 1 is when document should fully cover the image.
      • multiDocOnImage

        public java.lang.Boolean multiDocOnImage
        This option allows locating and cropping multiple documents from one image if enabled.
      • shiftExpiryDate

        public java.lang.Integer shiftExpiryDate
        This option allows shifting the date of expiry into the future or past for number of months specified. This is useful, for example, in some cases when document might be still valid for some period after original expiration date to prevent negative validity status for such documents. Or by shifting the date to the past will set negative validity for the documents that is about to expire in a specified number of months.
      • minimalHolderAge

        public java.lang.Integer minimalHolderAge
        This options allows specifying the minimal age in years of the document holder for the document to be considered valid.
      • mrzFormatsFilter

        public java.lang.String[] mrzFormatsFilter
        This option allows limiting MRZ formats to be recognized by specifying them in array.
      • forceReadMrzBeforeLocate

        public java.lang.Boolean forceReadMrzBeforeLocate
        This option can be set to true to make sure that in series processing MRZ is located fully inside the result document image, if present on the document. Enabling this option may add extra processing time, by disabling optimizations, but allows more stability in output image quality.
      • parseBarcodes

        public java.lang.Boolean parseBarcodes
        When set to false, the Barcode code parsing will be skipped and the raw information from the code will be returned instead.
      • disablePerforationOCR

        public java.lang.Boolean disablePerforationOCR
        When enabled, OCR of perforated fields in the document template will not be performed. Disabled by default.
      • documentGroupFilter

        public int[] documentGroupFilter
        List of specific eligible document types from DocumentType enum to recognize from. You may, for example, specify only passports to be recognized by setting this property. Empty by default.
      • respectImageQuality

        @Deprecated
        public java.lang.Boolean respectImageQuality
        Deprecated.
        When enabled, image quality checks status affects document optical and overall status. Disabled by default. use strictImageQuality instead
        Since:
        7.5
      • splitNames

        public java.lang.Boolean splitNames
        When enabled, the Surname and GivenNames field will be divided into ft_First_Name, ft_Second_Name, ft_Third_Name, ft_Fourth_Name, ft_Last_Name fields. Disabled by default.
      • shouldReturnPackageForReprocess

        public java.lang.Boolean shouldReturnPackageForReprocess
        When set to `true`, the DocumentReaderResults.rawResult property of the DocumentReaderResults will contain the encrypted containers of scanning results that may be used for later reprocessing.
      • processAuth

        public java.lang.Integer processAuth
        Accepts sum of eRPRM_Authenticity elements
      • convertCase

        public java.lang.Integer convertCase
        This option allows output text case transformation. No changes applied by default to original values.
      • useFaceApi

        public java.lang.Boolean useFaceApi
        Use this property to set up the Face API integration.
      • faceApiParams

        public FaceApiParams faceApiParams
        Set up the Face SDK service parameters,
      • backendProcessingConfig

        public BackendProcessingConfig backendProcessingConfig
        Set up the backend processing service parameters,
      • doDetectCan

        public java.lang.Boolean doDetectCan
        Enable the CAN (Card Access Number) detection when using scenarios with document location and MRZ reading, such as the MrzAndLocate scenario
      • lcidIgnoreFilter

        public int[] lcidIgnoreFilter
        The list of LCID types to ignore during the recognition. If empty, values with all LCID types will be extracted. Narrowing down the list can reduce processing time. Null by default. Use LCID.LCID_List elements
      • lcidFilter

        public int[] lcidFilter
        The list of LCID types to recognize. If empty, values with all LCID types will be extracted. Empty by default. Use LCID.LCID_List elements
      • doFlipYAxis

        public java.lang.Boolean doFlipYAxis
      • useAuthenticityCheck

        public java.lang.Boolean useAuthenticityCheck
      • logLevel

        public LogLevel logLevel
        Sets the level of logs detalization when used together with setLogs(Boolean) parameter.
      • mrzDetectMode

        public java.lang.Integer mrzDetectMode
        Make better MRZ detection on complex noisy backgrounds, like BW photocopy of some documents. Works only in the single-frame processing.
      • generateNumericCodes

        public java.lang.Boolean generateNumericCodes
        This parameter is used to generate numeric representation for issuing state and nationality codes
      • strictImageQuality

        public java.lang.Boolean strictImageQuality
        When enabled, the image quality check status affects the document optical and overall status.
      • generateDTCVC

        public java.lang.Boolean generateDTCVC
        This parameter is used to generate Dtc
      • strictBarcodeDigitalSignatureCheck

        public java.lang.Boolean strictBarcodeDigitalSignatureCheck
        If the certificates required for performing the Digital signature check are missing, this parameter if enabled will make the Barcode format check failed
      • selectLongestNames

        public java.lang.Boolean selectLongestNames
        Select the longest value from the different value sources and write it to the value field if comparison is done successfully. The parameter applies this logic to the personal names, such as given name, surname, surname and given name, middle name and etc.
    • Constructor Detail

      • ProcessParam

        public ProcessParam()
    • Method Detail

      • getCoreJson

        public java.lang.String getCoreJson()
        Method is returned process params to core for each frame
        Returns:
        json in string format
      • getRfidCoreJson

        public java.lang.String getRfidCoreJson()
        Method is returned process params to core during rfid reading
        Returns:
        json in string format
      • toJSONObject

        public JSONObject toJSONObject()
        Method converts params object to JSONObject instance
      • toJson

        public java.lang.String toJson()
        Method converts object to string in json format
        Returns:
        string in json format
      • fromJson

        public ProcessParam fromJson​(java.lang.String json)
        Converts properly formatted JSON string to the params object instance
      • isLogEnable

        public java.lang.Boolean isLogEnable()
        Indicates if logging to logcat console is enabled
      • setLogs

        public void setLogs​(java.lang.Boolean logs)
        Enables logging to the logcat console
      • setScenario

        public void setScenario​(java.lang.String scenario)
        Use this method to set the document processing scenario.
        Parameters:
        scenario - one of Scenario.Scenarios element
      • getScenario

        public java.lang.String getScenario()
        Returns the current document processing scenario.
        See Also:
        Scenario
      • isManualCropAvailable

        public boolean isManualCropAvailable()
        Flag, indicates if manual document boundaries setting is available