PassportRecognitionSettings

Inheritance: java.lang.Object, com.aspose.ocr.ReceiptRecognitionSettings

public class PassportRecognitionSettings extends ReceiptRecognitionSettings

Settings for the Passport recognition Contains elements that allow customizing the recognition process

Constructors

ConstructorDescription
PassportRecognitionSettings()

Methods

MethodDescription
equals(Object arg0)
getClass()
hashCode()
notify()
notifyAll()
setAllowedCharacters(CharactersAllowedType allowedCharacters)Allowed characters set.
setAllowedCharacters(String allowedCharacters)Allowed characters set.
setAutomaticColorInversion(boolean automaticColorInversion)Detect images with white text on dark/black background and automatically choose a special OCR algorithm for them.
setCountry(Country country)Set the template for passport recognition and to extract the keywords.
setIgnoredCharacters(String characters)Sets blacklist for recognition symbols.
setLanguage(Language language)
setThreadsCount(int threadsCount)Gets or sets the number of threads for processing.
setUpscaleSmallFont(boolean upscaleSmallFont)Allows you to use additional algorithms specifically for small font recognition.
toString()
wait()
wait(long arg0)
wait(long arg0, int arg1)

PassportRecognitionSettings()

public PassportRecognitionSettings()

equals(Object arg0)

public boolean equals(Object arg0)

Parameters:

ParameterTypeDescription
arg0java.lang.Object

Returns: boolean

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

hashCode()

public native int hashCode()

Returns: int

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

setAllowedCharacters(CharactersAllowedType allowedCharacters)

public void setAllowedCharacters(CharactersAllowedType allowedCharacters)

Allowed characters set. Determines the type of characters allowed for recognition result.

Parameters:

ParameterTypeDescription
allowedCharactersCharactersAllowedTypecontains enum @see CharactersAllowedType value.

setAllowedCharacters(String allowedCharacters)

public void setAllowedCharacters(String allowedCharacters)

Allowed characters set. Determines the array of characters allowed for recognition result.

Parameters:

ParameterTypeDescription
allowedCharactersjava.lang.Stringcontains array of characters.

setAutomaticColorInversion(boolean automaticColorInversion)

public void setAutomaticColorInversion(boolean automaticColorInversion)

Detect images with white text on dark/black background and automatically choose a special OCR algorithm for them.

Parameters:

ParameterTypeDescription
automaticColorInversionbooleancontains boolean value - a automaticColorInversion is set.

setCountry(Country country)

public void setCountry(Country country)

Set the template for passport recognition and to extract the keywords.

Parameters:

ParameterTypeDescription
countryCountry

setIgnoredCharacters(String characters)

public void setIgnoredCharacters(String characters)

Sets blacklist for recognition symbols.

Parameters:

ParameterTypeDescription
charactersjava.lang.StringCharacters excluded from recognition.

setLanguage(Language language)

public void setLanguage(Language language)

Parameters:

ParameterTypeDescription
languageLanguageSets the language used for OCR. Multi-language (none) by default.

setThreadsCount(int threadsCount)

public void setThreadsCount(int threadsCount)

Gets or sets the number of threads for processing. By default, 0 means that the image will be processed with the number of threads equal to your number of processors. ThreadsCount = 1 means that the image will be processed in the main thread.

Parameters:

ParameterTypeDescription
threadsCountintthe number of threads that will be created for parallel recognition of image fragments.

setUpscaleSmallFont(boolean upscaleSmallFont)

public void setUpscaleSmallFont(boolean upscaleSmallFont)

Allows you to use additional algorithms specifically for small font recognition. Useful for images with small size characters.

Parameters:

ParameterTypeDescription
upscaleSmallFontbooleancontains boolean value - a upscaleSmallFont is set.

toString()

public String toString()

Returns: java.lang.String

wait()

public final void wait()

wait(long arg0)

public final native void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int