text
stringlengths
14
100k
source
stringclasses
1 value
repo
stringclasses
810 values
language
stringclasses
13 values
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain<|fim_suffix|>f the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applic...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2013 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>ECBlocks(28, new ECB(19, 46), new ECB(4, 47)), new ECBlocks(28, new ECB(28, 22), new ECB(6, 23)), new ECBlocks(30, new ECB(33, 16), new ECB(4, 17))), new Version(27, new int[]{6, 34, 62, 90, 118}, new ECBlocks(30, ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|> final FinderPattern topRight; public FinderPatternInfo(FinderPattern[] patternCenters) { this.bottomLeft = patternCenters[0]; this.topLeft = patternCenters[1]; this.topRight = patternCenters[2]; } public FinderPattern getBottomLeft() { return bottomLeft; } public FinderPatter...
fim
zxing/zxing
java
<|fim_suffix|>ncoder; final class BlockPair { private final byte[] dataBytes; private final byte[] errorCorrectionBytes; BlockPair(byte[] data, byte[] errorCorrection) { dataBytes = data; errorCorrectionBytes = errorCorrection; } public byte[] getDataBytes() { return dataBytes; } public b...
fim
zxing/zxing
java
<|fim_suffix|> String toString() { StringBuilder result = new StringBuilder(2 * width * height + 2); for (int y = 0; y < height; ++y) { byte[] bytesY = bytes[y]; for (int x = 0; x < width; ++x) { switch (bytesY[x]) { case 0: result.append(" 0"); break; ...
fim
zxing/zxing
java
<|fim_suffix|> { bits.appendBits((i & 0x01) == 0 ? 0xEC : 0x11, 8); } if (bits.getSize() != capacity) { throw new WriterException("Bits size does not equal capacity"); } } /** * Get number of data bytes and number of error correction bytes for block id "blockID". Store * the result in...
fim
zxing/zxing
java
<|fim_suffix|>dth(); int fivePercentVariances = Math.abs(numDarkCells * 2 - numTotalCells) * 10 / numTotalCells; return fivePercentVariances * N4; } /** * Return the mask bit for "getMaskPattern" at "x" and "y". See 8.8 of JISX0510:2004 for mask * pattern conditions. */ static boolean getDataMas...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>otes a character unique to character set ISO-8859-2 and Y a * character unique to ISO-8859-3. Both characters encode as double byte in UTF-8: * * Initial situation * (initial) -- BYTE(X) (32) --> (1_BYTE_ISO-8859-2) * (initial) -- BYTE(X) (40) --> (1_BYTE_UTF-8) * (initial) -...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>redImageLuminanceSource(rotatedImage, top, sourceWidth - (left + width), getHeight(), width); } @Override public LuminanceSource rotateCounterClockwise45() { int width = getWidth(); int height = getHeight(); int oldCenterX = left + width / 2; int oldCenterY = top + height / 2; ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2014 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|> null)); } } <|fim_prefix|>/* * Copyright 2020 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2014 ZXing authors * * Licensed under the Apach<|fim_suffix|> assertEquals(Y, 0, source.getMatrix(), 0, Y.length); for (int r = 0; r < ROWS; r++) { assertEquals(Y, r * COLS, source.getRow(r, null), 0, COLS); } } @Test public void testCrop() { PlanarYUVLuminan...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2014 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>at.AZTEC); addTest(5, 5, 0.0f); addTest(4, 4, 90.0f); addTest(6, 6, 180.0f); addTest(3, 3, 270.0f); } } <|fim_prefix|>/* * Copyright 2011 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the Licen...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2014 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2013 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>ubstring(0, 100), 10, Encoder.DEFAULT_AZTEC_LAYERS); assertTrue(aztecCode.isCompact()); assertEquals(4, aztecCode.getLayers()); } // Helper routines private static void testEncode(String data, boolean compact, int layers, String expected) { AztecCode aztec = Encoder.encode(data, 33, En...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy <|fim_suffix|>123 Main St"}, null, null, null, null, null, null, null); } @Test public voi...
fim
zxing/zxing
java
<|fim_suffix|>TEND;VALUE=DATE:20111110\n" + "END:VEVENT", null, null, null, "20111110T000000Z", "20111110T000000Z"); } private static void doTest(String contents, String description, String summary, String ...
fim
zxing/zxing
java
<|fim_suffix|>sParsedResult) result; assertArrayEquals(tos, emailResult.getTos()); assertArrayEquals(ccs, emailResult.getCCs()); assertArrayEquals(bccs, emailResult.getBCCs()); assertEquals(subject, emailResult.getSubject()); assertEquals(body, emailResult.getBody()); } }<|fim_prefix|>/* * Copyr...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright (C) 2010 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applica...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>_13); doTest("01234565", "012345000065", BarcodeFormat.UPC_E); } private static void doTest(String contents, String normalized, BarcodeFormat format) { Result fakeResult = new Result(contents, null, null, format); ParsedResult result = ResultParser.parseResult(fakeResult); assertSame(...
fim
zxing/zxing
java
<|fim_suffix|>.getNumbers()); assertEquals(subject, smsResult.getSubject()); assertEquals(body, smsResult.getBody()); assertArrayEquals(new String[] { via }, smsResult.getVias()); assertEquals(parsedURI, smsResult.getSMSURI()); } } <|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under...
fim
zxing/zxing
java
<|fim_suffix|>.getTelURI()); } }<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 ...
fim
zxing/zxing
java
<|fim_suffix|> doTestIsPossiblyMalicious("http://google.com/foo@bar", false); doTestIsPossiblyMalicious("http://google.com/@@", false); } @Test public void testMaliciousUnicode() { doTestIsPossiblyMalicious("https://google.com\u2215.evil.com/stuff", true); doTestIsPossiblyMalicious("\u202ehttps://dy...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2014 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_suffix|> if (result == null) { result = barcodeReader.decode(source, hints); } if (expectedFormat != result.getBarcodeFormat()) { log.info(String.format("Format mismatch: expected '%s' but got '%s'%s", expectedFormat, result.getBarcodeFormat(), suffix)); re...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>y { emptyMatrix.clone().xor(badMatrix); fail(); } catch (IllegalArgumentException ex) { // good } try { badMatrix.clone().xor(emptyMatrix); fail(); } catch (IllegalArgumentException ex) { // good } } public static String matrixToString(BitMatri...
fim
zxing/zxing
java
<|fim_suffix|>time. * * @author Sean Owen */ public final class BitSourceBuilder { private final ByteArrayOutputStream output; private int nextByte; private int bitsLeftInNextByte; public BitSourceBuilder() { output = new ByteArrayOutputStream(); nextByte = 0; bitsLeftInNextByte = 8; } pub...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>rSetECI.UnicodeBigUnmarked, CharacterSetECI.getCharacterSetECI(StandardCharsets.UTF_16BE)); assertSame(CharacterSetECI.UnicodeBigUnmarked, CharacterSetECI.getCharacterSetECIByName("UTF-16BE")); assertSame(CharacterSetECI.UnicodeBigUnmarked, CharacterSetECI.getCharacterSetECIByValue(...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2007 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2012 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>s; } public int getMaxTryHarderMisreads() { return maxTryHarderMisreads; } public float getRotation() { return rotation; } } <|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in ...
fim
zxing/zxing
java
<|fim_suffix|>(1.9f)); assertEquals(2, MathUtils.round(2.1f)); assertEquals(3, MathUtils.round(2.5f)); assertEquals(-2, MathUtils.round(-1.9f)); assertEquals(-2, MathUtils.round(-2.1f)); assertEquals(-3, MathUtils.round(-2.5f)); // This differs from Math.round() assertEquals(Integer.MAX_VALU...
fim
zxing/zxing
java
<|fim_suffix|>At(0)); } } <|fim_prefix|>/* * Copyright 2018 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * U...
fim
zxing/zxing
java
<|fim_suffix|>Words.length); System.arraycopy(ecWords, 0, messageExpected, dataWords.length, ecWords.length); System.arraycopy(dataWords, 0, message, 0, dataWords.length); encoder.encode(message, ecWords.length); assertDataEquals("Encode in " + field + " (" + dataWords.length + ',' + ecWords.length + ")...
fim
zxing/zxing
java
<|fim_suffix|>; import com.google.zxing.common.AbstractBlackBoxTestCase; /** * @author bbrown@google.com (Brian Brown) */ public final class DataMatrixBlackBox1TestCase extends AbstractBlackBoxTestCase { public DataMatrixBlackBox1TestCase() { super("src/test/resources/blackbox/datamatrix-1", new MultiFormatRe...
fim
zxing/zxing
java
<|fim_suffix|> 180.0f); addTest(15, 15, 0, 1, 270.0f); } } <|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.ap...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>words, int numcols, int numrows) { super(codewords, numcols, numrows); } String[] toBitFieldStringArray() { byte[] bits = getBits(); int numrows = getNumrows(); int numcols = getNumcols(); String[] array = new String[numrows]; int startpos = 0; for (int row = 0; row ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2006 Jeremias Maerki. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a cop<|fim_suffix|> License. */ package com.google.zxing.datamatrix.encoder; import org.junit.Assert; import ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2006 Jeremias Maerki. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
fim
zxing/zxing
java
<|fim_prefix|>/* <|fim_suffix|>sertEquals("Row " + i, expected[i], actual[i]); } } private static String unvisualize(CharSequence visualized) { StringBuilder sb = new StringBuilder(); for (String token : SPACE.split(visualized)) { sb.append((char) Integer.parseInt(token)); } return sb.to...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2006 Jeremias Maerki * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicabl...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Lic<|fim_suffix|>d barcodes */ public final class InvertedDataMatrixBlackBoxTestCase extends AbstractBlackBoxTestCase { public InvertedDataMatrixBlackBoxTestCase() { super("src/test/resources/blackbox/inverted", new MultiFormatReader(), BarcodeFormat.DATA_M...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless r<|fim_suffix|>hint inv...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2016 ZX<|fim_suffix|>f the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either...
fim
zxing/zxing
java
/* * Copyright 2016 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_suffix|>reader = new QRCodeMultiReader(); Result[] results = reader.decodeMultiple(bitmap); assertNotNull(results); assertEquals(4, results.length); Collection<String> barcodeContents = new HashSet<>(); for (Result result : results) { barcodeContents.add(result.getText()); assertE...
fim
zxing/zxing
java
/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License<|fim_suffix|>st(1, 270.0f); } } <|fim_middle|>"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/license...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You <|fim_suffix|>r dswitkin@google.com (Daniel Switkin) */ public final class UnsupportedBlackBoxTestCase extends AbstractNegati...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2011 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * Y<|fim_suffix|>10101001" + "0101001101" + "0110010101" + "01101101011" + "01001001011" + "00000"); } @T...
fim
zxing/zxing
java
<|fim_suffix|>atReader; import com.google.zxing.common.AbstractBlackBoxTestCase; /** * @author Sean Owen */ public final class CodabarBlackBox1TestCase extends AbstractBlackBoxTestCase { public CodabarBlackBox1TestCase() { super("src/test/resources/blackbox/codabar-1", new MultiFormatReader(), BarcodeFormat.C...
fim
zxing/zxing
java
<|fim_suffix|>S IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.google.zxing.oned; import com.google.zxing.BarcodeFormat; import com.google.zxing.MultiFormatR...
fim
zxing/zxing
java
<|fim_suffix|>(Daniel Switkin) */ public final class Code128BlackBox2TestCase extends AbstractBlackBoxTestCase { public Code128BlackBox2TestCase() { super("src/test/resources/blackbox/code128-2", new MultiFormatReader(), BarcodeFormat.CODE_128); addTest(36, 39, 0.0f); addTest(36, 39, 180.0f); } }<|fi...
fim
zxing/zxing
java
<|fim_suffix|> public Code128BlackBox3TestCase() { super("src/test/resources/blackbox/code128-3", new MultiFormatReader(), BarcodeFormat.CODE_128); addTest(2, 2, 0.0f); addTest(2, 2, 180.0f); } }<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "L...
fim
zxing/zxing
java
<|fim_suffix|>ssertTrue(result.getWidth() <= width); } @Test(expected = IllegalArgumentException.class) public void testEncodeWithForcedCodeSetFailureCodeSetABadCharacter() throws Exception { // Lower case characters should not be accepted when the code set is forced to A. String toEncode = "ASDFx0123";...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>ARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.google.zxing.oned; import com.google.zxing.BarcodeFormat; import com.google.zxing.MultiFormatReader; import com.google....
fim
zxing/zxing
java
<|fim_suffix|>rmat.CODE_39); addTest(2, 2, 0.0f); addTest(2, 2, 180.0f); } }<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * ...
fim
zxing/zxing
java
<|fim_suffix|>{ // expected } } } private static void doTest(String expectedResult, String encodedResult) throws FormatException, ChecksumException, NotFoundException { Code39Reader sut = new Code39Reader(false, true); BitMatrix matrix = BitMatrix.parse(encodedResult, "1", "0"); ...
fim
zxing/zxing
java
/* * Copyright 2016 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>sut = new Code93Reader(); BitMatrix matrix = BitMatrix.parse(encodedResult, "1", "0"); BitArray row = new BitArray(matrix.getWidth()); matrix.getRow(0, row); Result result = sut.decodeRow(0, row, null); assertEquals(expectedResult, result.getText()); } } <|fim_prefix|>/* * Copyrigh...
fim
zxing/zxing
java
<|fim_suffix|>01011010001011001" + "001011000101001101001000110101010110001010011001010001101001011001000101101101101001" + "101100101101011001101001101100101101100110101011011001011001101001101101001110101000" + "1010010100100010100010010100001010010100010010010010010001010101000010001...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE<|fim_suffix|>t/resources/blackbox/ean13-...
fim
zxing/zxing
java
<|fim_suffix|> com.google.zxing.BarcodeFormat; import com.google.zxing.MultiFormatReader; import com.google.zxing.common.AbstractBlackBoxTestCase; /** * This is a set of mobile image taken at 480x360 with difficult lighting. * * @author dswitkin@google.com (Daniel Switkin) */ public final class EAN13BlackBox2TestC...
fim
zxing/zxing
java
<|fim_suffix|>kin@google.com (Daniel Switkin) */ public final class EAN13BlackBox3TestCase extends AbstractBlackBoxTestCase { public EAN13BlackBox3TestCase() { super("src/test/resources/blackbox/ean13-3", new MultiFormatReader(), BarcodeFormat.EAN_13); addTest(53, 55, 0.0f); addTest(55, 55, 180.0f); }...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2009 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
/* * Copyright 2011 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2009 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable<...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the Licen<|fim_suffix|>.MultiFormatReader; import com.google.zxing.common.AbstractBlackBoxTestCase; /** * @author Sean Owen */ public final cla...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2009 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_suffix|>/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with <|fim_suffix|>quired by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * W...
fim
zxing/zxing
java
<|fim_suffix|>ltiFormatReader; import com.google.zxing.common.AbstractBlackBoxTestCase; /** * @author dswitkin@google.com (Daniel Switkin) */ public final class ITFBlackBox2TestCase extends AbstractBlackBoxTestCase { public ITFBlackBox2TestCase() { super("src/test/resources/blackbox/itf-2", new MultiFormatRea...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2017 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java
/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed ...
fim
zxing/zxing
java
<|fim_prefix|>/* * Copyright 2008 ZXing authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable ...
fim
zxing/zxing
java