"Split" ReaderException into subclasses to enable more useful error reporting
[zxing.git] / core / src / com / google / zxing / pdf417 / decoder / BitMatrixParser.java
index dc27a8b..03c12ac 100644 (file)
@@ -16,7 +16,7 @@
 \r
 package com.google.zxing.pdf417.decoder;\r
 \r
-import com.google.zxing.ReaderException;\r
+import com.google.zxing.NotFoundException;\r
 import com.google.zxing.common.BitMatrix;\r
 \r
 /**\r
@@ -190,7 +190,7 @@ final class BitMatrixParser {
     for (int i = 0; i < width; i += MODULES_IN_SYMBOL) {\r
       for (int mask = MODULES_IN_SYMBOL - 1; mask >= 0; mask--) {\r
         if (rowCounters[i + (MODULES_IN_SYMBOL - 1 - mask)] >= rowHeight >>> 1) {\r
-          symbol |= 1 << mask;\r
+          symbol |= 1L << mask;\r
         }\r
       }\r
       if (columnNumber > 0) {\r
@@ -305,7 +305,7 @@ final class BitMatrixParser {
    * @param symbol\r
    * @return the codeword corresponding to the symbol.\r
    */\r
-  private int getCodeword(long symbol) {\r
+  private static int getCodeword(long symbol) {\r
     long sym = symbol;\r
     sym &= 0x3ffff;\r
     int i = findCodewordIndex(sym);\r
@@ -379,7 +379,7 @@ final class BitMatrixParser {
    * @param next        the next available index into the codewords array.\r
    * @return the next available index into the codeword array after processing\r
    *         this row.\r
-   * @throws ReaderException\r
+   * @throws NotFoundException\r
    */\r
   /*\r
   int processRow1(int[] rowCounters, int rowNumber, int rowHeight,\r