Base64
, EightBit
, HeaderLine
, HTML
, QuotedPrintable
, SevenBit
public abstract class Encoding extends Object
Constructor | Description |
---|---|
Encoding() |
Modifier and Type | Method | Description |
---|---|---|
Buffer |
decode(byte[] in) |
This implementation just calls decode(in, 0, in.length).
|
Buffer |
decode(byte[] in,
int offset,
int length) |
|
Buffer |
decode(Buffer in) |
This implementation just calls decode(in.content, in.offset, in.length).
|
void |
decode(Buffer in,
Buffer out) |
|
abstract void |
decode(InputStream in,
Buffer out) |
|
Buffer |
decode(String str) |
This implementation just converts the string to a byte array
and then calls encode(byte[]).
|
abstract String |
encode(byte[] in) |
Encode a byte array to a ASCII or ISO-8859-1 String.
|
void |
encode(InputStream in,
Writer out) |
Encode an input stream of bytes to a ASCII or ISO-8859-1 String.
|
String |
encode(String str) |
Encode a (UTF-8) String to a ASCII or ISO-8859-1 String.
|
abstract String |
getName() |
public abstract String getName()
public abstract String encode(byte[] in) throws EncodingException
in
- EncodingException
public String encode(String str) throws EncodingException
str
- EncodingException
encode(byte[])
public void encode(InputStream in, Writer out) throws IOException
IOException
public Buffer decode(byte[] in) throws DecodingException
in
- DecodingException
decode(byte[], int, int)
public Buffer decode(byte[] in, int offset, int length) throws DecodingException
in
- offset
- length
- DecodingException
public Buffer decode(String str) throws DecodingException
str
- DecodingException
decode(byte[], int, int)
public Buffer decode(Buffer in) throws IOException
in
- DecodingException
IOException
decode(byte[], int, int)
public void decode(Buffer in, Buffer out) throws IOException
in
- DecodingException
IOException
decode(byte[], int, int)
public abstract void decode(InputStream in, Buffer out) throws IOException
in
- DecodingException
IOException
decode(byte[], int, int)