public final class Code128Writer extends OneDimensionalCodeWriter
BitMatrix
.Modifier and Type | Class and Description |
---|---|
private static class |
Code128Writer.CType |
private static class |
Code128Writer.MinimalEncoder
Encodes minimally using Divide-And-Conquer with Memoization
|
Modifier and Type | Field and Description |
---|---|
private static int |
CODE_CODE_A |
private static int |
CODE_CODE_B |
private static int |
CODE_CODE_C |
private static int |
CODE_FNC_1 |
private static int |
CODE_FNC_2 |
private static int |
CODE_FNC_3 |
private static int |
CODE_FNC_4_A |
private static int |
CODE_FNC_4_B |
private static int |
CODE_START_A |
private static int |
CODE_START_B |
private static int |
CODE_START_C |
private static int |
CODE_STOP |
private static char |
ESCAPE_FNC_1 |
private static char |
ESCAPE_FNC_2 |
private static char |
ESCAPE_FNC_3 |
private static char |
ESCAPE_FNC_4 |
Constructor and Description |
---|
Code128Writer() |
Modifier and Type | Method and Description |
---|---|
private static int |
check(java.lang.String contents,
java.util.Map<EncodeHintType,?> hints) |
private static int |
chooseCode(java.lang.CharSequence value,
int start,
int oldCode) |
boolean[] |
encode(java.lang.String contents)
Encode the contents to boolean array expression of one-dimensional barcode.
|
boolean[] |
encode(java.lang.String contents,
java.util.Map<EncodeHintType,?> hints)
Can be overwritten if the encode requires to read the hints map.
|
private static boolean[] |
encodeFast(java.lang.String contents,
int forcedCodeSet) |
private static Code128Writer.CType |
findCType(java.lang.CharSequence value,
int start) |
protected java.util.Collection<BarcodeFormat> |
getSupportedWriteFormats() |
(package private) static boolean[] |
produceResult(java.util.Collection<int[]> patterns,
int checkSum) |
appendPattern, checkNumeric, encode, encode, getDefaultMargin
private static final int CODE_START_A
private static final int CODE_START_B
private static final int CODE_START_C
private static final int CODE_CODE_A
private static final int CODE_CODE_B
private static final int CODE_CODE_C
private static final int CODE_STOP
private static final char ESCAPE_FNC_1
private static final char ESCAPE_FNC_2
private static final char ESCAPE_FNC_3
private static final char ESCAPE_FNC_4
private static final int CODE_FNC_1
private static final int CODE_FNC_2
private static final int CODE_FNC_3
private static final int CODE_FNC_4_A
private static final int CODE_FNC_4_B
protected java.util.Collection<BarcodeFormat> getSupportedWriteFormats()
getSupportedWriteFormats
in class OneDimensionalCodeWriter
public boolean[] encode(java.lang.String contents)
OneDimensionalCodeWriter
encode
in class OneDimensionalCodeWriter
contents
- barcode contents to encodeboolean[]
of horizontal pixels (false = white, true = black)public boolean[] encode(java.lang.String contents, java.util.Map<EncodeHintType,?> hints)
OneDimensionalCodeWriter
encode
.encode
in class OneDimensionalCodeWriter
contents
- barcode contents to encodehints
- encoding hintsboolean[]
of horizontal pixels (false = white, true = black)private static int check(java.lang.String contents, java.util.Map<EncodeHintType,?> hints)
private static boolean[] encodeFast(java.lang.String contents, int forcedCodeSet)
static boolean[] produceResult(java.util.Collection<int[]> patterns, int checkSum)
private static Code128Writer.CType findCType(java.lang.CharSequence value, int start)
private static int chooseCode(java.lang.CharSequence value, int start, int oldCode)