import com.google.zxing.BarcodeFormat;
import com.google.zxing.DecodeHintType;
+import com.google.zxing.NotFoundException;
+import com.google.zxing.Reader;
import com.google.zxing.ReaderException;
import com.google.zxing.Result;
import com.google.zxing.common.BitArray;
*
* @author Sean Owen
*/
-public final class MultiFormatUPCEANReader extends AbstractOneDReader {
+public final class MultiFormatUPCEANReader extends OneDReader {
private final Vector readers;
}
}
- public Result decodeRow(int rowNumber, BitArray row, Hashtable hints) throws ReaderException {
+ public Result decodeRow(int rowNumber, BitArray row, Hashtable hints) throws NotFoundException {
// Compute this location once and reuse it on multiple implementations
- int[] startGuardPattern = AbstractUPCEANReader.findStartGuardPattern(row);
+ int[] startGuardPattern = UPCEANReader.findStartGuardPattern(row);
int size = readers.size();
for (int i = 0; i < size; i++) {
UPCEANReader reader = (UPCEANReader) readers.elementAt(i);
return result;
}
- throw ReaderException.getInstance();
+ throw NotFoundException.getNotFoundInstance();
+ }
+
+ public void reset() {
+ int size = readers.size();
+ for (int i = 0; i < size; i++) {
+ Reader reader = (Reader) readers.elementAt(i);
+ reader.reset();
+ }
}
}