public abstract class Encoder extends Object
Modifier and Type | Class and Description |
---|---|
protected class |
Encoder.FixedCharArrayWriter
CharArrayWriter that allows one to specify the char array buffer
in which to write.
|
Constructor and Description |
---|
Encoder() |
Modifier and Type | Method and Description |
---|---|
char[] |
decode(char[] src)
Decodes from the format.
|
int |
decode(char[] src,
char[] dst,
int doffset)
Decodes from the format to the specified char array.
|
char[] |
decode(char[] src,
int soffset,
int length)
Decodes from the format.
|
abstract int |
decode(char[] src,
int soffset,
int length,
Writer dst)
Decodes from the format.
|
int |
decode(char[] src,
Writer dst)
Decodes from the format to the specified char array.
|
String |
decode(String src)
Decodes from the format.
|
int |
decode(String src,
Writer dst)
Decodes from the format to the specified string.
|
char[] |
encode(char[] src)
Encodes to the format.
|
int |
encode(char[] src,
char[] dst,
int doffset)
Encodes to the format to the specified char array.
|
char[] |
encode(char[] src,
int soffset,
int length)
Encodes to the format.
|
abstract int |
encode(char[] src,
int soffset,
int length,
Writer dst)
Encodes to the format.
|
int |
encode(char[] src,
Writer dst)
Encodes to the format to the specified char array.
|
String |
encode(String src)
Encodes to the format.
|
int |
encode(String src,
Writer dst)
Encodes to the format to the specified string.
|
public String encode(String src)
src
- String to encode.public String decode(String src)
src
- String to decode.public char[] encode(char[] src)
src
- Char array to encode.public char[] decode(char[] src)
src
- Char array to decode.public int encode(char[] src, char[] dst, int doffset)
src
- Char array to encode.dst
- Char array in which write the encoded chars.doffset
- Offset in the dst char array at which to begin writing.public int decode(char[] src, char[] dst, int doffset)
src
- Char array to decode.dst
- Char array in which to write the decoded chars.doffset
- Offset in the dst char array at which to begin writing.public int encode(String src, Writer dst) throws IOException
src
- String to encode.dst
- Writer in which to write the encoded chars.IOException
public int decode(String src, Writer dst) throws IOException
src
- String to decode.dst
- Writer in which write the encoded chars.IOException
public int encode(char[] src, Writer dst) throws IOException
src
- Char array to encode.dst
- Writer in which to write the encoded chars.IOException
public int decode(char[] src, Writer dst) throws IOException
src
- Char array to decode.dst
- Writer in which write the encoded chars.IOException
public char[] encode(char[] src, int soffset, int length)
src
- Char array to encode.soffset
- Offset in the src array at which to begin reading.length
- Length of src array to encode.public char[] decode(char[] src, int soffset, int length)
src
- Char array to decode.soffset
- Offset in the src array at which to begin reading.length
- Length of src array to decode.public abstract int encode(char[] src, int soffset, int length, Writer dst) throws IOException
src
- Char array to encode.soffset
- Offset in the src array at which to begin reading.length
- Length of src array to encode.dst
- Writer in which to write the encoded chars.IOException
public abstract int decode(char[] src, int soffset, int length, Writer dst) throws IOException
src
- Char array to decode.soffset
- Offset in the src array at which to begin reading.length
- Length of src array to decode.dst
- Writer in which to write the decoded chars.IOException