public class BarcodePDF417
extends java.lang.Object
限定符和类型 | 类和说明 |
---|---|
protected static class |
BarcodePDF417.Segment |
protected static class |
BarcodePDF417.SegmentList |
限定符和类型 | 字段和说明 |
---|---|
protected static int |
ABSOLUTE_MAX_TEXT_SIZE |
protected static int |
AL |
protected static int |
ALPHA |
protected static int |
AS |
protected int |
bitPtr |
protected static int |
BYTE_MODE |
protected static int |
BYTE_MODE_6 |
protected static int |
BYTESHIFT |
protected int |
cwPtr |
protected static float |
DEFAUL_MODULE_HEIGHT |
protected static float |
DEFAUL_MODULE_WIDTH |
protected static int |
ISBYTE |
protected static int |
LL |
protected static int |
LOWER |
protected static int |
MACRO_LAST_SEGMENT |
protected static int |
MACRO_SEGMENT_ID |
protected static int |
MAX_DATA_CODEWORDS |
protected static int |
MIXED |
protected static int |
ML |
protected static int |
MOD |
protected static int |
NUMERIC_MODE |
protected static int |
PAL |
static int |
PDF417_AUTO_ERROR_LEVEL
The error level correction is set automatically according
to ISO 15438 recommendations.
|
static int |
PDF417_FIXED_COLUMNS
The size will be at least
codeColumns
with a variable number of codeRows . |
static int |
PDF417_FIXED_RECTANGLE
The size of the barcode will be at least
codeColumns*codeRows . |
static int |
PDF417_FIXED_ROWS
The size will be at least
codeRows
with a variable number of codeColumns . |
static int |
PDF417_FORCE_BINARY
One single binary segment is used
|
static int |
PDF417_INVERT_BITMAP
Inverts the output bits of the raw bitmap that is normally
bit one for black.
|
static int |
PDF417_USE_ASPECT_RATIO
Auto-size is made based on
aspectRatio and yHeight . |
static int |
PDF417_USE_ERROR_LEVEL
The error level correction is set by the user.
|
static int |
PDF417_USE_MACRO
Use Macro PDF417 Encoding
|
static int |
PDF417_USE_RAW_CODEWORDS
No
text interpretation is done and the content of codewords
is used directly. |
protected static int |
PL |
protected static int |
PS |
protected static int |
PUNCTUATION |
protected BarcodePDF417.SegmentList |
segmentList |
protected static int |
SPACE |
protected static int |
START_CODE_SIZE |
protected static int |
START_PATTERN |
protected static int |
STOP_PATTERN |
protected static int |
STOP_SIZE |
protected static int |
TEXT_MODE |
构造器和说明 |
---|
BarcodePDF417()
Creates a new
BarcodePDF417 with the default settings. |
限定符和类型 | 方法和说明 |
---|---|
protected void |
assemble() |
protected void |
basicNumberCompaction(int start,
int length) |
protected void |
byteCompaction6(int start) |
protected void |
calculateErrorCorrection(int dest) |
protected boolean |
checkSegmentType(BarcodePDF417.Segment segment,
char type) |
int |
getBitColumns()
Gets the number of X pixels of
outBits . |
byte[] |
getCode()
Gets the bytes that form the barcode.
|
int |
getCodeRows()
Gets the number of Y pixels of
outBits . |
protected int |
getMaxSquare() |
int |
getOptions()
Gets the options to generate the barcode.
|
byte[] |
getOutBits()
Gets the raw image bits of the barcode.
|
protected int |
getSegmentLength(BarcodePDF417.Segment segment) |
protected int |
getTextTypeAndValue(int maxLength,
int idx) |
protected static int |
maxPossibleErrorLevel(int remain) |
protected void |
numberCompaction(int start,
int length) |
protected void |
outCodeword(int codeword) |
protected void |
outCodeword17(int codeword) |
protected void |
outCodeword18(int codeword) |
protected void |
outPaintCode() |
protected void |
outStartPattern() |
protected void |
outStopPattern() |
void |
paintCode()
Paints the barcode.
|
void |
setCode(byte[] code)
Sets the bytes that form the barcode.
|
void |
setCode(java.lang.String text)
Sets the code that will form the barcode.
|
void |
setDefaultParameters()
Set the default settings that correspond to
PDF417_USE_ASPECT_RATIO
and PDF417_AUTO_ERROR_LEVEL . |
void |
setOptions(int options)
Sets the options to generate the barcode.
|
protected void |
textCompaction(int start,
int length) |
public static final int PDF417_USE_ASPECT_RATIO
aspectRatio
and yHeight
.public static final int PDF417_FIXED_RECTANGLE
codeColumns*codeRows
.public static final int PDF417_FIXED_COLUMNS
codeColumns
with a variable number of codeRows
.public static final int PDF417_FIXED_ROWS
codeRows
with a variable number of codeColumns
.public static final int PDF417_AUTO_ERROR_LEVEL
public static final int PDF417_USE_ERROR_LEVEL
public static final int PDF417_FORCE_BINARY
public static final int PDF417_USE_RAW_CODEWORDS
text
interpretation is done and the content of codewords
is used directly.public static final int PDF417_INVERT_BITMAP
public static final int PDF417_USE_MACRO
protected static final int START_PATTERN
protected static final int STOP_PATTERN
protected static final int START_CODE_SIZE
protected static final int STOP_SIZE
protected static final int MOD
protected static final int ALPHA
protected static final int LOWER
protected static final int MIXED
protected static final int PUNCTUATION
protected static final int ISBYTE
protected static final int BYTESHIFT
protected static final int PL
protected static final int LL
protected static final int AS
protected static final int ML
protected static final int AL
protected static final int PS
protected static final int PAL
protected static final int SPACE
protected static final int TEXT_MODE
protected static final int BYTE_MODE_6
protected static final int BYTE_MODE
protected static final int NUMERIC_MODE
protected static final int ABSOLUTE_MAX_TEXT_SIZE
protected static final int MAX_DATA_CODEWORDS
protected static final int MACRO_SEGMENT_ID
protected static final int MACRO_LAST_SEGMENT
protected static final float DEFAUL_MODULE_WIDTH
protected static final float DEFAUL_MODULE_HEIGHT
protected int bitPtr
protected int cwPtr
protected BarcodePDF417.SegmentList segmentList
public void setDefaultParameters()
PDF417_USE_ASPECT_RATIO
and PDF417_AUTO_ERROR_LEVEL
.public void paintCode() throws PdfException
PdfException
public byte[] getOutBits()
yHeight
.public int getBitColumns()
outBits
.outBits
public int getCodeRows()
outBits
.
It is also the number of rows in the barcode.outBits
public byte[] getCode()
public void setCode(byte[] code)
code
- the bytes that form the barcodepublic void setCode(java.lang.String text)
text
- the text that will form the barcodepublic int getOptions()
public void setOptions(int options)
PDF417_*
constants.options
- the options to generate the barcodeprotected void outCodeword17(int codeword)
protected void outCodeword18(int codeword)
protected void outCodeword(int codeword)
protected void outStopPattern()
protected void outStartPattern()
protected void outPaintCode()
protected void calculateErrorCorrection(int dest)
protected void textCompaction(int start, int length) throws PdfException
PdfException
protected void basicNumberCompaction(int start, int length)
protected int getTextTypeAndValue(int maxLength, int idx)
protected boolean checkSegmentType(BarcodePDF417.Segment segment, char type)
protected int getSegmentLength(BarcodePDF417.Segment segment)
protected void numberCompaction(int start, int length) throws PdfException
PdfException
protected void byteCompaction6(int start)
protected void assemble() throws PdfException
PdfException
protected static int maxPossibleErrorLevel(int remain)
protected int getMaxSquare()