BarcodeOptions

Inheritance: java.lang.Object

public class BarcodeOptions

Provides the options which are used for barcode extraction.

Constructors

Constructor Description
BarcodeOptions() Initializes a new instance of the BarcodeOptions class with default values.
BarcodeOptions(Rectangle rectangle) Initializes a new instance of the BarcodeOptions class with the rectangular area.
BarcodeOptions(QualityMode imageQuality, QualityMode barcodeQuality, String[] codeTypes) Initializes a new instance of the BarcodeOptions class with quality settings and code types.
BarcodeOptions(Rectangle rectangle, QualityMode imageQuality, QualityMode barcodeQuality, Float dimension, boolean allowIncorrectBarcodes, String[] codeTypes) Initializes a new instance of the BarcodeOptions class.

Methods

Method Description
isAllowIncorrectBarcodes() Gets the value that indicates whether the incorrect barcodes are allowed.
getDimension() Gets the minimal size of the barcode minimal element.
getImageQuality() Gets the quality of a source image.
getBarcodeQuality() Gets the quality of a source barcode.
getRectangle() Gets the rectangular area that contains page areas.
getCodeTypes() Gets the types of barcodes to read.
setAllowIncorrectBarcodes(boolean allowIncorrectBarcodes) Sets the value that indicates whether the incorrect barcodes are allowed.
setDimension(Float dimension) Sets the minimal size of the barcode minimal element.
setImageQuality(QualityMode imageQuality) Sets the quality of a source image.
setBarcodeQuality(QualityMode barcodeQuality) Sets the quality of a source barcode.
setRectangle(Rectangle rectangle) Sets the rectangular area that contains barcodes.
setCodeTypes(List codeTypes) Sets the types of barcodes to read.

BarcodeOptions()

public BarcodeOptions()

Initializes a new instance of the BarcodeOptions class with default values.

BarcodeOptions(Rectangle rectangle)

public BarcodeOptions(Rectangle rectangle)

Initializes a new instance of the BarcodeOptions class with the rectangular area.

Parameters:

Parameter Type Description
rectangle Rectangle The rectangular area that contains barcodes.

BarcodeOptions(QualityMode imageQuality, QualityMode barcodeQuality, String[] codeTypes)

public BarcodeOptions(QualityMode imageQuality, QualityMode barcodeQuality, String[] codeTypes)

Initializes a new instance of the BarcodeOptions class with quality settings and code types.

Parameters:

Parameter Type Description
imageQuality QualityMode The quality of a source image.
barcodeQuality QualityMode The quality of a source barcode.
codeTypes java.lang.String[] The types of barcodes to read.

BarcodeOptions(Rectangle rectangle, QualityMode imageQuality, QualityMode barcodeQuality, Float dimension, boolean allowIncorrectBarcodes, String[] codeTypes)

public BarcodeOptions(Rectangle rectangle, QualityMode imageQuality, QualityMode barcodeQuality, Float dimension, boolean allowIncorrectBarcodes, String[] codeTypes)

Initializes a new instance of the BarcodeOptions class.

Parameters:

Parameter Type Description
rectangle Rectangle The rectangular area that contains barcodes.
imageQuality QualityMode The quality of a source image.
barcodeQuality QualityMode The quality of a source barcode.
dimension java.lang.Float The minimal size of the barcode minimal element.
allowIncorrectBarcodes boolean The value that indicates whether the incorrect barcodes are allowed.
codeTypes java.lang.String[] The types of barcodes to read.

isAllowIncorrectBarcodes()

public boolean isAllowIncorrectBarcodes()

Gets the value that indicates whether the incorrect barcodes are allowed.

Returns: boolean - true if the incorrect barcodes are allowed; otherwise, false .

getDimension()

public Float getDimension()

Gets the minimal size of the barcode minimal element.

Returns: java.lang.Float - The float value that represents the barcode minimal element; null if auto mode is used.

getImageQuality()

public QualityMode getImageQuality()

Gets the quality of a source image.

Returns: QualityMode - The mode which defines the level of the source image quality.

getBarcodeQuality()

public QualityMode getBarcodeQuality()

Gets the quality of a source barcode.

Returns: QualityMode - The mode which defines the level of the source barcode quality.

getRectangle()

public Rectangle getRectangle()

Gets the rectangular area that contains page areas.

Returns: Rectangle - An instance of Rectangle class that represents the rectangular area that contains page areas; null if it isn’t set.

getCodeTypes()

public List<String> getCodeTypes()

Gets the types of barcodes to read.

Returns: java.util.List<java.lang.String> - The readonly collection that contains a types of barcodes to read; empty collection if isn’t set.

setAllowIncorrectBarcodes(boolean allowIncorrectBarcodes)

public void setAllowIncorrectBarcodes(boolean allowIncorrectBarcodes)

Sets the value that indicates whether the incorrect barcodes are allowed.

Parameters:

Parameter Type Description
allowIncorrectBarcodes boolean true if the incorrect barcodes are allowed.

setDimension(Float dimension)

public void setDimension(Float dimension)

Sets the minimal size of the barcode minimal element.

Parameters:

Parameter Type Description
dimension java.lang.Float The barcode minimal element; null for auto mode.

setImageQuality(QualityMode imageQuality)

public void setImageQuality(QualityMode imageQuality)

Sets the quality of a source image.

Parameters:

Parameter Type Description
imageQuality QualityMode The image quality mode.

setBarcodeQuality(QualityMode barcodeQuality)

public void setBarcodeQuality(QualityMode barcodeQuality)

Sets the quality of a source barcode.

Parameters:

Parameter Type Description
barcodeQuality QualityMode The barcode quality mode.

setRectangle(Rectangle rectangle)

public void setRectangle(Rectangle rectangle)

Sets the rectangular area that contains barcodes.

Parameters:

Parameter Type Description
rectangle Rectangle The rectangular area; null to scan the whole page.

setCodeTypes(List codeTypes)

public void setCodeTypes(List<String> codeTypes)

Sets the types of barcodes to read.

Parameters:

Parameter Type Description
codeTypes java.util.List<java.lang.String> The types of barcodes; null or empty for all types.