Package com.google.zxing.oned
Class CodaBarWriter
- java.lang.Object
-
- com.google.zxing.oned.OneDimensionalCodeWriter
-
- com.google.zxing.oned.CodaBarWriter
-
- All Implemented Interfaces:
Writer
public final class CodaBarWriter extends OneDimensionalCodeWriter
This class renders CodaBar asboolean[]
.
-
-
Field Summary
Fields Modifier and Type Field Description private static char[]
ALT_START_END_CHARS
private static char[]
CHARS_WHICH_ARE_TEN_LENGTH_EACH_AFTER_DECODED
private static char
DEFAULT_GUARD
private static char[]
START_END_CHARS
-
Constructor Summary
Constructors Constructor Description CodaBarWriter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean[]
encode(java.lang.String contents)
Encode the contents to boolean array expression of one-dimensional barcode.protected java.util.Collection<BarcodeFormat>
getSupportedWriteFormats()
-
Methods inherited from class com.google.zxing.oned.OneDimensionalCodeWriter
appendPattern, checkNumeric, encode, encode, encode, getDefaultMargin
-
-
-
-
Field Detail
-
START_END_CHARS
private static final char[] START_END_CHARS
-
ALT_START_END_CHARS
private static final char[] ALT_START_END_CHARS
-
CHARS_WHICH_ARE_TEN_LENGTH_EACH_AFTER_DECODED
private static final char[] CHARS_WHICH_ARE_TEN_LENGTH_EACH_AFTER_DECODED
-
DEFAULT_GUARD
private static final char DEFAULT_GUARD
-
-
Method Detail
-
getSupportedWriteFormats
protected java.util.Collection<BarcodeFormat> getSupportedWriteFormats()
- Overrides:
getSupportedWriteFormats
in classOneDimensionalCodeWriter
-
encode
public boolean[] encode(java.lang.String contents)
Description copied from class:OneDimensionalCodeWriter
Encode the contents to boolean array expression of one-dimensional barcode. Start code and end code should be included in result, and side margins should not be included.- Specified by:
encode
in classOneDimensionalCodeWriter
- Parameters:
contents
- barcode contents to encode- Returns:
- a
boolean[]
of horizontal pixels (false = white, true = black)
-
-