Package org.jcodings.transcode
Class TranscodeFunctions
- java.lang.Object
-
- org.jcodings.transcode.TranscodeFunctions
-
public class TranscodeFunctions extends java.lang.Object
Created by headius on 3/4/14.
-
-
Field Summary
Fields Modifier and Type Field Description static int
BE
static int
EMACS_MULE_LEADING_CODE_JISX0208_1978
static int
EMACS_MULE_LEADING_CODE_JISX0208_1983
private static int
ESCAPE_END
private static int
ESCAPE_NORMAL
static int
from_UTF_16BE_D8toDB_00toFF
static int
from_UTF_16LE_00toFF_D8toDB
private static int
from_utf8_mac_nfc2
static byte
G0_ASCII
static byte
G0_JISX0201_KATAKANA
static byte
G0_JISX0208_1978
static byte
G0_JISX0208_1983
static int
iso2022jp_decoder_jisx0208_rest
static int
iso2022jp_kddi_decoder_jisx0208_rest
static int
LE
private static int
MET_CR
private static int
MET_CRLF
private static int
MET_LF
private static int
NEWLINE_JUST_AFTER_CR
private static int
NEWLINE_NORMAL
private static int
STATUS_BUF_SIZE
static byte[]
tbl0208
private static int
TOTAL_BUF_SIZE
-
Constructor Summary
Constructors Constructor Description TranscodeFunctions()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static int
BL_BASE(int nextInfo)
private static int
BL_INFO(int nextInfo)
private static int
bufApply(byte[] sp, byte[] o, int oStart)
private static byte
bufAt(byte[] sp, int pos)
private static int
bufBeg(byte[] statep)
private static void
bufBeg(byte[] statep, int end)
private static int
bufBegPostInc(byte[] statep)
private static int
bufBytesize(byte[] p)
private static void
bufClear(byte[] state)
private static boolean
bufEmpty(byte[] sp)
private static int
bufEnd(byte[] statep)
private static void
bufEnd(byte[] statep, int end)
private static int
bufEndPostInc(byte[] statep)
private static int
bufInt(byte[] statep, int base)
private static void
bufInt(byte[] statep, int base, int val)
private static int
bufOutputAll(byte[] sp, byte[] o, int oStart)
private static int
bufOutputChar(byte[] sp, byte[] o, int oStart)
private static void
bufPush(byte[] sp, byte[] p, int pStart, int l)
private static byte
bufShift(byte[] sp)
private static int
BYTE_ADDR(int index)
private static int
BYTE_LOOKUP_BASE(int bl)
private static int
BYTE_LOOKUP_INFO(int bl)
static int
escapeXmlAttrQuoteFinish(byte[] statep, byte[] o, int oStart, int oSize)
static int
escapeXmlAttrQuoteInit(byte[] statep)
static int
finishCp50220Encoder(byte[] statep, byte[] o, int oStart, int size)
static int
finishIso2022jpEncoder(byte[] statep, byte[] o, int oStart, int oSize)
static int
finishIso2022jpKddiEncoder(byte[] statep, byte[] o, int oStart, int oSize)
static int
fromUtf8MacFinish(byte[] statep, byte[] o, int oStart, int oSize)
static int
fromUtf8MacInit(byte[] state)
static int
funSiCp50221Decoder(byte[] statep, byte[] s, int sStart, int l)
static int
funSiFromUTF16(byte[] statep, byte[] s, int sStart, int l)
static int
funSiFromUTF32(byte[] statep, byte[] s, int sStart, int l)
static int
funSiIso2022jpKddiDecoder(byte[] statep, byte[] s, int sStart, int l)
static int
funSiIso50220jpDecoder(byte[] statep, byte[] s, int sStart, int l)
static int
funSioFromGB18030(byte[] statep, byte[] s, int sStart, int l, int info, byte[] o, int oStart, int osize)
static int
funSioToGB18030(byte[] statep, byte[] s, int sStart, int l, int info, byte[] o, int oStart, int osize)
static int
funSoCp50220Encoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoCp50221Decoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoCp5022xEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoEscapeXmlAttrQuote(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoEucjp2Sjis(byte[] statep, byte[] s, int sStart, int _l, byte[] o, int oStart, int osize)
static int
funSoEucjpToStatelessIso2022jp(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoFromGB18030(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF16(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF16BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF16LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF32(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF32BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUTF32LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoFromUtf8Mac(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoIso2022jpDecoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoIso2022jpEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoIso2022jpKddiDecoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoIso2022jpKddiEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoSjis2Eucjp(byte[] statep, byte[] s, int sStart, int _l, byte[] o, int oStart, int osize)
static int
funSoStatelessIso2022jpToEucjp(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
static int
funSoToGB18030(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF16(byte[] statep, byte[] sBytes, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF16BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF16LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF32(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF32BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoToUTF32LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
static int
funSoUniversalNewline(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
private static int
getInfo(int nextInfo, byte[] sp)
static int
iso2022jpEncoderResetSequenceSize(byte[] statep)
static int
iso2022jpInit(byte[] state)
static int
iso2022jpKddiEncoderResetSequence_size(byte[] statep)
static int
iso2022jpKddiInit(byte[] statep)
private static void
NEWLINE_NEWLINES_MET(byte[] sp, int b)
private static void
NEWLINE_NEWLINES_MET_or_mask(byte[] sp, int b)
private static byte
NEWLINE_STATE(byte[] sp)
private static void
NEWLINE_STATE(byte[] sp, int b)
static int
universalNewlineFinish(byte[] statep, byte[] o, int oStart, int oSize)
static int
universalNewlineInit(byte[] statep)
static int
UTF8MAC_BL_ACTION(int nextInfo, byte b)
static int
UTF8MAC_BL_MAX_BYTE(int nextInfo)
static int
UTF8MAC_BL_MIN_BYTE(int nextInfo)
static int
UTF8MAC_BL_OFFSET(int nextInfo, int b)
private static boolean
utf8Trailbyte(byte c)
private static int
WORD_ADDR(int index)
-
-
-
Field Detail
-
BE
public static final int BE
- See Also:
- Constant Field Values
-
LE
public static final int LE
- See Also:
- Constant Field Values
-
from_UTF_16BE_D8toDB_00toFF
public static final int from_UTF_16BE_D8toDB_00toFF
-
from_UTF_16LE_00toFF_D8toDB
public static final int from_UTF_16LE_00toFF_D8toDB
-
G0_ASCII
public static final byte G0_ASCII
- See Also:
- Constant Field Values
-
G0_JISX0208_1978
public static final byte G0_JISX0208_1978
- See Also:
- Constant Field Values
-
G0_JISX0208_1983
public static final byte G0_JISX0208_1983
- See Also:
- Constant Field Values
-
G0_JISX0201_KATAKANA
public static final byte G0_JISX0201_KATAKANA
- See Also:
- Constant Field Values
-
EMACS_MULE_LEADING_CODE_JISX0208_1978
public static final int EMACS_MULE_LEADING_CODE_JISX0208_1978
- See Also:
- Constant Field Values
-
EMACS_MULE_LEADING_CODE_JISX0208_1983
public static final int EMACS_MULE_LEADING_CODE_JISX0208_1983
- See Also:
- Constant Field Values
-
tbl0208
public static final byte[] tbl0208
-
iso2022jp_decoder_jisx0208_rest
public static final int iso2022jp_decoder_jisx0208_rest
-
iso2022jp_kddi_decoder_jisx0208_rest
public static final int iso2022jp_kddi_decoder_jisx0208_rest
-
STATUS_BUF_SIZE
private static final int STATUS_BUF_SIZE
- See Also:
- Constant Field Values
-
TOTAL_BUF_SIZE
private static final int TOTAL_BUF_SIZE
- See Also:
- Constant Field Values
-
from_utf8_mac_nfc2
private static final int from_utf8_mac_nfc2
-
ESCAPE_END
private static final int ESCAPE_END
- See Also:
- Constant Field Values
-
ESCAPE_NORMAL
private static final int ESCAPE_NORMAL
- See Also:
- Constant Field Values
-
NEWLINE_NORMAL
private static final int NEWLINE_NORMAL
- See Also:
- Constant Field Values
-
NEWLINE_JUST_AFTER_CR
private static final int NEWLINE_JUST_AFTER_CR
- See Also:
- Constant Field Values
-
MET_LF
private static final int MET_LF
- See Also:
- Constant Field Values
-
MET_CRLF
private static final int MET_CRLF
- See Also:
- Constant Field Values
-
MET_CR
private static final int MET_CR
- See Also:
- Constant Field Values
-
-
Method Detail
-
funSoToUTF16
public static int funSoToUTF16(byte[] statep, byte[] sBytes, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoToUTF16BE
public static int funSoToUTF16BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoToUTF16LE
public static int funSoToUTF16LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoToUTF32
public static int funSoToUTF32(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoToUTF32BE
public static int funSoToUTF32BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoToUTF32LE
public static int funSoToUTF32LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSiFromUTF32
public static int funSiFromUTF32(byte[] statep, byte[] s, int sStart, int l)
-
funSoFromUTF32
public static int funSoFromUTF32(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoFromUTF32BE
public static int funSoFromUTF32BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoFromUTF32LE
public static int funSoFromUTF32LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSiFromUTF16
public static int funSiFromUTF16(byte[] statep, byte[] s, int sStart, int l)
-
funSoFromUTF16
public static int funSoFromUTF16(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoFromUTF16BE
public static int funSoFromUTF16BE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoFromUTF16LE
public static int funSoFromUTF16LE(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSoEucjp2Sjis
public static int funSoEucjp2Sjis(byte[] statep, byte[] s, int sStart, int _l, byte[] o, int oStart, int osize)
-
funSoSjis2Eucjp
public static int funSoSjis2Eucjp(byte[] statep, byte[] s, int sStart, int _l, byte[] o, int oStart, int osize)
-
funSoFromGB18030
public static int funSoFromGB18030(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSioFromGB18030
public static int funSioFromGB18030(byte[] statep, byte[] s, int sStart, int l, int info, byte[] o, int oStart, int osize)
-
funSoToGB18030
public static int funSoToGB18030(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int osize)
-
funSioToGB18030
public static int funSioToGB18030(byte[] statep, byte[] s, int sStart, int l, int info, byte[] o, int oStart, int osize)
-
iso2022jpInit
public static int iso2022jpInit(byte[] state)
-
funSoCp50220Encoder
public static int funSoCp50220Encoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
funSoCp5022xEncoder
public static int funSoCp5022xEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
finishCp50220Encoder
public static int finishCp50220Encoder(byte[] statep, byte[] o, int oStart, int size)
-
iso2022jpEncoderResetSequenceSize
public static int iso2022jpEncoderResetSequenceSize(byte[] statep)
-
funSiIso50220jpDecoder
public static int funSiIso50220jpDecoder(byte[] statep, byte[] s, int sStart, int l)
-
funSoIso2022jpDecoder
public static int funSoIso2022jpDecoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
funSoStatelessIso2022jpToEucjp
public static int funSoStatelessIso2022jpToEucjp(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
funSoEucjpToStatelessIso2022jp
public static int funSoEucjpToStatelessIso2022jp(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
funSoIso2022jpEncoder
public static int funSoIso2022jpEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
finishIso2022jpEncoder
public static int finishIso2022jpEncoder(byte[] statep, byte[] o, int oStart, int oSize)
-
funSiCp50221Decoder
public static int funSiCp50221Decoder(byte[] statep, byte[] s, int sStart, int l)
-
funSoCp50221Decoder
public static int funSoCp50221Decoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
iso2022jpKddiInit
public static int iso2022jpKddiInit(byte[] statep)
-
funSiIso2022jpKddiDecoder
public static int funSiIso2022jpKddiDecoder(byte[] statep, byte[] s, int sStart, int l)
-
funSoIso2022jpKddiDecoder
public static int funSoIso2022jpKddiDecoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
funSoIso2022jpKddiEncoder
public static int funSoIso2022jpKddiEncoder(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
finishIso2022jpKddiEncoder
public static int finishIso2022jpKddiEncoder(byte[] statep, byte[] o, int oStart, int oSize)
-
iso2022jpKddiEncoderResetSequence_size
public static int iso2022jpKddiEncoderResetSequence_size(byte[] statep)
-
fromUtf8MacInit
public static int fromUtf8MacInit(byte[] state)
-
bufBytesize
private static final int bufBytesize(byte[] p)
-
bufAt
private static final byte bufAt(byte[] sp, int pos)
-
bufClear
private static void bufClear(byte[] state)
-
funSoFromUtf8Mac
public static int funSoFromUtf8Mac(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
bufPush
private static void bufPush(byte[] sp, byte[] p, int pStart, int l)
-
bufApply
private static int bufApply(byte[] sp, byte[] o, int oStart)
-
bufEmpty
private static boolean bufEmpty(byte[] sp)
-
bufShift
private static byte bufShift(byte[] sp)
-
utf8Trailbyte
private static boolean utf8Trailbyte(byte c)
-
bufOutputChar
private static int bufOutputChar(byte[] sp, byte[] o, int oStart)
-
getInfo
private static int getInfo(int nextInfo, byte[] sp)
-
UTF8MAC_BL_MIN_BYTE
public static int UTF8MAC_BL_MIN_BYTE(int nextInfo)
-
UTF8MAC_BL_MAX_BYTE
public static int UTF8MAC_BL_MAX_BYTE(int nextInfo)
-
UTF8MAC_BL_OFFSET
public static int UTF8MAC_BL_OFFSET(int nextInfo, int b)
-
UTF8MAC_BL_ACTION
public static int UTF8MAC_BL_ACTION(int nextInfo, byte b)
-
BL_BASE
private static int BL_BASE(int nextInfo)
-
BL_INFO
private static int BL_INFO(int nextInfo)
-
BYTE_ADDR
private static int BYTE_ADDR(int index)
-
WORD_ADDR
private static int WORD_ADDR(int index)
-
BYTE_LOOKUP_BASE
private static int BYTE_LOOKUP_BASE(int bl)
-
BYTE_LOOKUP_INFO
private static int BYTE_LOOKUP_INFO(int bl)
-
bufInt
private static int bufInt(byte[] statep, int base)
-
bufInt
private static void bufInt(byte[] statep, int base, int val)
-
bufBeg
private static int bufBeg(byte[] statep)
-
bufEnd
private static int bufEnd(byte[] statep)
-
bufBeg
private static void bufBeg(byte[] statep, int end)
-
bufEnd
private static void bufEnd(byte[] statep, int end)
-
bufEndPostInc
private static int bufEndPostInc(byte[] statep)
-
bufBegPostInc
private static int bufBegPostInc(byte[] statep)
-
fromUtf8MacFinish
public static int fromUtf8MacFinish(byte[] statep, byte[] o, int oStart, int oSize)
-
bufOutputAll
private static int bufOutputAll(byte[] sp, byte[] o, int oStart)
-
escapeXmlAttrQuoteInit
public static int escapeXmlAttrQuoteInit(byte[] statep)
-
funSoEscapeXmlAttrQuote
public static int funSoEscapeXmlAttrQuote(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
escapeXmlAttrQuoteFinish
public static int escapeXmlAttrQuoteFinish(byte[] statep, byte[] o, int oStart, int oSize)
-
NEWLINE_STATE
private static byte NEWLINE_STATE(byte[] sp)
-
NEWLINE_STATE
private static void NEWLINE_STATE(byte[] sp, int b)
-
NEWLINE_NEWLINES_MET
private static void NEWLINE_NEWLINES_MET(byte[] sp, int b)
-
NEWLINE_NEWLINES_MET_or_mask
private static void NEWLINE_NEWLINES_MET_or_mask(byte[] sp, int b)
-
universalNewlineInit
public static int universalNewlineInit(byte[] statep)
-
funSoUniversalNewline
public static int funSoUniversalNewline(byte[] statep, byte[] s, int sStart, int l, byte[] o, int oStart, int oSize)
-
universalNewlineFinish
public static int universalNewlineFinish(byte[] statep, byte[] o, int oStart, int oSize)
-
-