Class DocumentDataExtractorConfigurationBuilder
-
- All Implemented Interfaces:
public final class DocumentDataExtractorConfigurationBuilderA builder class to help with assembling the configuration for DocumentDataExtractor.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classDocumentDataExtractorConfigurationBuilder.Companion
-
Field Summary
Fields Modifier and Type Field Description public final static DocumentDataExtractorConfigurationBuilder.CompanionCompanion
-
Constructor Summary
Constructors Constructor Description DocumentDataExtractorConfigurationBuilder()
-
Method Summary
Modifier and Type Method Description final DocumentDataExtractorConfigurationBuildersetReturnCrops(Boolean returnCrops)Sets whether the extractor should return the crops of the detected document data fields. final DocumentDataExtractorConfigurationBuildersetAcceptedDocumentTypes(List<RootDocumentType> types)Sets the accepted document data types. final DocumentDataExtractorConfigurationBuildersetMachineReadableZoneConfiguration(MrzFallbackConfiguration config)Lets you fine-tune the data extraction of machine-readable-zone-based documents. final DocumentDataExtractorConfigurationBuildersetEuropeanHealthInsuranceCardConfiguration(EuropeanHealthInsuranceCardConfiguration config)Lets you fine-tune the data extraction of EU health insurance cards. final DocumentDataExtractorConfigurationBuilderaddDateValidatorConfiguration(DateValidationConfiguration config)Adds a date validation config for a single field. final DocumentDataExtractorConfigurationBuilderaddExcludedField(String fieldName)Excludes fields with the specified field name from the result. final DocumentDataExtractorConfigurationBuildersetResultAccumulationConfig(ResultAccumulationConfiguration config)Lets you fine-tune the accumulation of live data extraction results. final DocumentDataExtractorConfigurationbuild()Builds the final configuration that can be passed to the document data extractor. -
-
Method Detail
-
setReturnCrops
final DocumentDataExtractorConfigurationBuilder setReturnCrops(Boolean returnCrops)
Sets whether the extractor should return the crops of the detected document data fields.
- Parameters:
returnCrops- Whether the extractor should return the crops of the detected document data fields.
-
setAcceptedDocumentTypes
final DocumentDataExtractorConfigurationBuilder setAcceptedDocumentTypes(List<RootDocumentType> types)
Sets the accepted document data types. The extractor will only extract documents of these types.
- Parameters:
types- The array of document data types that will be extracted.
-
setMachineReadableZoneConfiguration
final DocumentDataExtractorConfigurationBuilder setMachineReadableZoneConfiguration(MrzFallbackConfiguration config)
Lets you fine-tune the data extraction of machine-readable-zone-based documents. Setting this property will automatically add the document type RootDocumentType.MRZ to the accepted document types.
- Parameters:
config- The machine-readable-zone-based document data extractor configuration.
-
setEuropeanHealthInsuranceCardConfiguration
final DocumentDataExtractorConfigurationBuilder setEuropeanHealthInsuranceCardConfiguration(EuropeanHealthInsuranceCardConfiguration config)
Lets you fine-tune the data extraction of EU health insurance cards. Setting this property will automatically add the document type RootDocumentType.EuropeanHealthInsuranceCard to the accepted document types.
- Parameters:
config- The machine-readable-zone-based document data extractor configuration.
-
addDateValidatorConfiguration
final DocumentDataExtractorConfigurationBuilder addDateValidatorConfiguration(DateValidationConfiguration config)
Adds a date validation config for a single field. Existing date validators for the specified field will be overwritten.
- Parameters:
config- The date validation configuration to be used to validate the field specified in the configuration.
-
addExcludedField
final DocumentDataExtractorConfigurationBuilder addExcludedField(String fieldName)
Excludes fields with the specified field name from the result.
- Parameters:
fieldName- The name of the field to be excluded from the extractor result.
-
setResultAccumulationConfig
final DocumentDataExtractorConfigurationBuilder setResultAccumulationConfig(ResultAccumulationConfiguration config)
Lets you fine-tune the accumulation of live data extraction results.
- Parameters:
config- The accumulation configuration.
-
build
final DocumentDataExtractorConfiguration build()
Builds the final configuration that can be passed to the document data extractor.
-
-
-
-