Package com.google.zxing.oned
Class MultiFormatUPCEANReader
- java.lang.Object
-
- com.google.zxing.oned.OneDReader
-
- com.google.zxing.oned.MultiFormatUPCEANReader
-
- All Implemented Interfaces:
Reader
public final class MultiFormatUPCEANReader extends OneDReader
A reader that can read all available UPC/EAN formats. If a caller wants to try to read all such formats, it is most efficient to use this implementation rather than invoke individual readers.
-
-
Field Summary
Fields Modifier and Type Field Description private static UPCEANReader[]EMPTY_READER_ARRAYprivate UPCEANReader[]readers
-
Constructor Summary
Constructors Constructor Description MultiFormatUPCEANReader(java.util.Map<DecodeHintType,?> hints)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ResultdecodeRow(int rowNumber, BitArray row, java.util.Map<DecodeHintType,?> hints)Attempts to decode a one-dimensional barcode format given a single row of an image.voidreset()Resets any internal state the implementation has after a decode, to prepare it for reuse.-
Methods inherited from class com.google.zxing.oned.OneDReader
decode, decode, patternMatchVariance, recordPattern, recordPatternInReverse
-
-
-
-
Field Detail
-
EMPTY_READER_ARRAY
private static final UPCEANReader[] EMPTY_READER_ARRAY
-
readers
private final UPCEANReader[] readers
-
-
Constructor Detail
-
MultiFormatUPCEANReader
public MultiFormatUPCEANReader(java.util.Map<DecodeHintType,?> hints)
-
-
Method Detail
-
decodeRow
public Result decodeRow(int rowNumber, BitArray row, java.util.Map<DecodeHintType,?> hints) throws NotFoundException
Description copied from class:OneDReaderAttempts to decode a one-dimensional barcode format given a single row of an image.
- Specified by:
decodeRowin classOneDReader- Parameters:
rowNumber- row number from top of the rowrow- the black/white pixel data of the rowhints- decode hints- Returns:
Resultcontaining encoded string and start/end of barcode- Throws:
NotFoundException- if no potential barcode is found
-
reset
public void reset()
Description copied from interface:ReaderResets any internal state the implementation has after a decode, to prepare it for reuse.- Specified by:
resetin interfaceReader- Overrides:
resetin classOneDReader
-
-