public final class MultiFormatReader extends java.lang.Object implements Reader
Modifier and Type | Field and Description |
---|---|
private static Reader[] |
EMPTY_READER_ARRAY |
private java.util.Map<DecodeHintType,?> |
hints |
private Reader[] |
readers |
Constructor and Description |
---|
MultiFormatReader() |
Modifier and Type | Method and Description |
---|---|
Result |
decode(BinaryBitmap image)
This version of decode honors the intent of Reader.decode(BinaryBitmap) in that it
passes null as a hint to the decoders.
|
Result |
decode(BinaryBitmap image,
java.util.Map<DecodeHintType,?> hints)
Decode an image using the hints provided.
|
private Result |
decodeInternal(BinaryBitmap image) |
Result |
decodeWithState(BinaryBitmap image)
Decode an image using the state set up by calling setHints() previously.
|
void |
reset()
Resets any internal state the implementation has after a decode, to prepare it
for reuse.
|
void |
setHints(java.util.Map<DecodeHintType,?> hints)
This method adds state to the MultiFormatReader.
|
private static final Reader[] EMPTY_READER_ARRAY
private java.util.Map<DecodeHintType,?> hints
private Reader[] readers
public Result decode(BinaryBitmap image) throws NotFoundException
decode
in interface Reader
image
- The pixel data to decodeNotFoundException
- Any errors which occurredpublic Result decode(BinaryBitmap image, java.util.Map<DecodeHintType,?> hints) throws NotFoundException
decode
in interface Reader
image
- The pixel data to decodehints
- The hints to use, clearing the previous state.NotFoundException
- Any errors which occurredpublic Result decodeWithState(BinaryBitmap image) throws NotFoundException
image
- The pixel data to decodeNotFoundException
- Any errors which occurredpublic void setHints(java.util.Map<DecodeHintType,?> hints)
hints
- The set of hints to use for subsequent calls to decode(image)public void reset()
Reader
private Result decodeInternal(BinaryBitmap image) throws NotFoundException
NotFoundException