static Result constructResult(List<ExpandedPair> pairs) throws NotFoundException, FormatException { BitArray binary = BitArrayBuilder.buildBitArray(pairs); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(binary); String resultingString = decoder.parseInformation(); ResultPoint[] firstPoints = pairs.get(0).getFinderPattern().getResultPoints(); ResultPoint[] lastPoints = pairs.get(pairs.size() - 1).getFinderPattern().getResultPoints(); return new Result( resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED ); }
private static Result constructResult(List<ExpandedPair> pairs) throws NotFoundException{ BitArray binary = BitArrayBuilder.buildBitArray(pairs); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(binary); String resultingString = decoder.parseInformation(); ResultPoint[] firstPoints = pairs.get(0).getFinderPattern().getResultPoints(); ResultPoint[] lastPoints = pairs.get(pairs.size() - 1).getFinderPattern().getResultPoints(); return new Result( resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED ); }
static Result constructResult(List<ExpandedPair> pairs) throws NotFoundException { BitArray binary = BitArrayBuilder.buildBitArray(pairs); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(binary); String resultingString = decoder.parseInformation(); ResultPoint[] firstPoints = pairs.get(0).getFinderPattern().getResultPoints(); ResultPoint[] lastPoints = pairs.get(pairs.size() - 1).getFinderPattern().getResultPoints(); return new Result( resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED ); }
static Result constructResult(List<ExpandedPair> pairs) throws NotFoundException{ BitArray binary = BitArrayBuilder.buildBitArray(pairs); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(binary); String resultingString = decoder.parseInformation(); ResultPoint[] firstPoints = pairs.get(0).getFinderPattern().getResultPoints(); ResultPoint[] lastPoints = pairs.get(pairs.size() - 1).getFinderPattern().getResultPoints(); return new Result( resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED ); }
private static Result constructResult(Vector pairs) throws NotFoundException{ BitArray binary = BitArrayBuilder.buildBitArray(pairs); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(binary); String resultingString = decoder.parseInformation(); ResultPoint [] firstPoints = ((ExpandedPair)pairs.elementAt(0)).getFinderPattern().getResultPoints(); ResultPoint [] lastPoints = ((ExpandedPair)pairs.lastElement()).getFinderPattern().getResultPoints(); return new Result( resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED ); }
static Result constructResult(List<ExpandedPair> pairs) throws NotFoundException, FormatException { String resultingString = AbstractExpandedDecoder.createDecoder(BitArrayBuilder .buildBitArray(pairs)).parseInformation(); ResultPoint[] firstPoints = ((ExpandedPair) pairs.get(0)).getFinderPattern() .getResultPoints(); ResultPoint[] lastPoints = ((ExpandedPair) pairs.get(pairs.size() - 1)).getFinderPattern ().getResultPoints(); return new Result(resultingString, null, new ResultPoint[]{firstPoints[0], firstPoints[1], lastPoints[0], lastPoints[1]}, BarcodeFormat.RSS_EXPANDED); }
private static Result a(List list) { String s = AbstractExpandedDecoder.createDecoder(com.google.zxing.oned.rss.expanded.a.a(list)).parseInformation(); ResultPoint aresultpoint[] = ((b)list.get(0)).d().getResultPoints(); ResultPoint aresultpoint1[] = ((b)list.get(-1 + list.size())).d().getResultPoints(); ResultPoint aresultpoint2[] = new ResultPoint[4]; aresultpoint2[0] = aresultpoint[0]; aresultpoint2[1] = aresultpoint[1]; aresultpoint2[2] = aresultpoint1[0]; aresultpoint2[3] = aresultpoint1[1]; return new Result(s, null, aresultpoint2, BarcodeFormat.RSS_EXPANDED); }
@Test public void testNoAi() throws Exception { BitArray information = BinaryUtil.buildBitArrayFromString(" .......X ..XX..X. X.X....X .......X ...."); AbstractExpandedDecoder decoder = AbstractExpandedDecoder.createDecoder(information); String decoded = decoder.parseInformation(); assertEquals("(10)12A", decoded); }