|
barcode4j 2.1.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.krysalis.barcode4j.impl.code39.Code39LogicImpl
public class Code39LogicImpl
This class is an implementation of the Code39 barcode.
Constructor Summary | |
---|---|
Code39LogicImpl(ChecksumMode mode,
boolean displayStartStop,
boolean displayChecksum,
boolean extendedCharSet)
Main constructor |
Method Summary | |
---|---|
static char |
calcChecksum(java.lang.String msg)
Calculates the checksum for a message to be encoded as an Code39 barcode. |
protected void |
encodeChar(ClassicBarcodeLogicHandler logic,
char c)
Encodes a single character. |
static java.lang.StringBuffer |
escapeExtended(java.lang.String msg,
java.lang.StringBuffer sb)
Escapes US-ASCII characters as required for the extended character set for Code 39. |
void |
generateBarcodeLogic(ClassicBarcodeLogicHandler logic,
java.lang.String msg)
Generates the barcode logic |
ChecksumMode |
getChecksumMode()
Returns the currently active checksum mode. |
static boolean |
validateChecksum(java.lang.String msg)
Verifies the checksum for a message. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Code39LogicImpl(ChecksumMode mode, boolean displayStartStop, boolean displayChecksum, boolean extendedCharSet)
mode
- checksum modedisplayStartStop
- Controls whether to display start and stop
characters in the human-readable messagedisplayChecksum
- Controls whether to display checksum
in the human-readable messageMethod Detail |
---|
public ChecksumMode getChecksumMode()
public static java.lang.StringBuffer escapeExtended(java.lang.String msg, java.lang.StringBuffer sb)
msg
- the original messagesb
- the StringBuffer to write the escaped message to (or null)
public static char calcChecksum(java.lang.String msg)
msg
- message to calculate the check digit for
public static boolean validateChecksum(java.lang.String msg)
msg
- message (check digit included)
protected void encodeChar(ClassicBarcodeLogicHandler logic, char c)
logic
- the logic handler to receive generated eventsc
- the character to encodepublic void generateBarcodeLogic(ClassicBarcodeLogicHandler logic, java.lang.String msg)
logic
- the logic handler to receive generated eventsmsg
- the message to encode
|
barcode4j 2.1.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |