DataMatrixInfo.java 2.48 KB
/*
 * Decompiled with CFR 0_118.
 */
package com.adobe.xfa.pmp.datamatrixpmp;

class DataMatrixInfo {
    static final int[] NUM_ROWS = new int[]{10, 12, 14, 16, 18, 20, 22, 24, 26, 32, 36, 40, 44, 48, 52, 64, 72, 80, 88, 96, 104, 120, 132, 144, 8, 8, 12, 12, 16, 16};
    static final int[] NUM_COLS = new int[]{10, 12, 14, 16, 18, 20, 22, 24, 26, 32, 36, 40, 44, 48, 52, 64, 72, 80, 88, 96, 104, 120, 132, 144, 18, 32, 26, 36, 36, 48};
    static final int[] TOTAL_SYMBOLS = new int[]{8, 12, 18, 24, 32, 40, 50, 60, 72, 98, 128, 162, 200, 242, 288, 392, 512, 648, 800, 968, 1152, 1458, 1800, 2178, 12, 21, 30, 40, 56, 77};
    static final int[] DATA_SYMBOLS = new int[]{3, 5, 8, 12, 18, 22, 30, 36, 44, 62, 86, 114, 144, 174, 204, 280, 368, 456, 576, 696, 816, 1050, 1304, 1558, 5, 10, 16, 22, 32, 49};
    static final int[] CHECK_SYMBOLS = new int[]{5, 7, 10, 12, 14, 18, 20, 24, 28, 36, 42, 48, 56, 68, 84, 112, 144, 192, 224, 272, 336, 408, 496, 620, 7, 11, 14, 18, 24, 28};
    static final int[] NUM_INTERLEAVES = new int[]{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 4, 4, 4, 4, 6, 6, 8, 10, 1, 1, 1, 1, 1, 1};
    static final int[] CHECK_BLOCK_SIZE = new int[]{5, 7, 10, 12, 14, 18, 20, 24, 28, 36, 42, 48, 56, 68, 42, 56, 36, 48, 56, 68, 56, 68, 62, 62, 7, 11, 14, 18, 24, 28};

    DataMatrixInfo() {
    }

    static enum Sizes {
        SIZE_10_10(0),
        SIZE_12_12(1),
        SIZE_14_14(2),
        SIZE_16_16(3),
        SIZE_18_18(4),
        SIZE_20_20(5),
        SIZE_22_22(6),
        SIZE_24_24(7),
        SIZE_26_26(8),
        SIZE_32_32(9),
        SIZE_36_36(10),
        SIZE_40_40(11),
        SIZE_44_44(12),
        SIZE_48_48(13),
        SIZE_52_52(14),
        SIZE_64_64(15),
        SIZE_72_72(16),
        SIZE_80_80(17),
        SIZE_88_88(18),
        SIZE_96_96(19),
        SIZE_104_104(20),
        SIZE_120_120(21),
        SIZE_132_132(22),
        SIZE_144_144(23),
        SIZE_8_18(24),
        SIZE_8_32(25),
        SIZE_12_26(26),
        SIZE_12_36(27),
        SIZE_16_36(28),
        SIZE_16_48(29),
        NUM_SIZES(30),
        NUM_SQUARE_SIZES(24);
        
        int value;

        private Sizes(int value) {
            this.value = value;
        }

        public int getValue() {
            return this.value;
        }

        public static Sizes getInstance(int value) {
            for (Sizes size : Sizes.values()) {
                if (size.value != value) continue;
                return size;
            }
            return null;
        }
    }

}