|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.wimpi.pim.util.EncodingUtility
Utility class providing encoding and decoding methods.
Base64
,
QuotedPrintable
Constructor Summary | |
EncodingUtility()
|
Method Summary | |
static byte[] |
decodeBase64(byte[] data)
Returns the decoded data. |
static byte[] |
decodeBase64(java.lang.String data)
Returns the decoded String. |
static java.lang.String |
decodeQP(java.lang.String data)
Returns the decoded String. |
static byte[] |
encodeBase64(byte[] data)
Returns the Base64 encoded data. |
static byte[] |
encodeLineBreaks(byte[] data)
Encodes line breaks into an escape sequence. |
static java.io.InputStream |
encodeLineBreaks(java.io.InputStream data)
Returns an InputStream filtering raw line breaks into escape sequences. |
static java.lang.String |
encodeLineBreaks(java.lang.String str)
Convenience method that encodes line breaks into an escape sequence. |
static java.lang.String |
encodeQP(java.lang.String data)
Returns the encoded String. |
static byte[] |
removeWhiteSpace(byte[] data)
Removes whitespace from the given data. |
static java.io.InputStream |
removeWhiteSpace(java.io.InputStream data)
Returns an InputStream which will not include any whitespace from the passed in InputStream. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public EncodingUtility()
Method Detail |
public static byte[] decodeBase64(byte[] data)
data
- the Base64 encoded data.
public static byte[] decodeBase64(java.lang.String data)
data
- a Base64 encoded String.
public static byte[] encodeBase64(byte[] data)
data
- the data to be encoded.
public static java.lang.String decodeQP(java.lang.String data)
data
- a Quoted-Printable encoded String.
public static java.lang.String encodeQP(java.lang.String data)
data
- a String to be Quoted-Printable encoded.
public static byte[] removeWhiteSpace(byte[] data)
data
- the data as byte[].
public static java.io.InputStream removeWhiteSpace(java.io.InputStream data) throws java.io.IOException
data
- the data as InputStream.
java.io.IOException
- if an I/O error occurs.public static byte[] encodeLineBreaks(byte[] data)
data
- the data with raw line breaks.
public static java.lang.String encodeLineBreaks(java.lang.String str)
str
- the data with raw line breaks as String.
public static java.io.InputStream encodeLineBreaks(java.io.InputStream data) throws java.io.IOException
data
- an InputStream.
java.io.IOException
- if an I/O error occurs.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |