Package com.kheops.util
Class Base64Coder
java.lang.Object
com.kheops.util.Base64Coder
- 
Constructor SummaryConstructors
- 
Method Summary
- 
Constructor Details- 
Base64Coderpublic Base64Coder()
 
- 
- 
Method Details- 
encodeEncodes a string into Base64 format. No blanks or line breaks are inserted.- Parameters:
- s- a String to be encoded.
- Returns:
- A String with the Base64 encoded data.
 
- 
encodepublic static char[] encode(byte[] in) Encodes a byte array into Base64 format. No blanks or line breaks are inserted.- Parameters:
- in- an array containing the data bytes to be encoded.
- Returns:
- A character array with the Base64 encoded data.
 
- 
decodeDecodes a Base64 string.- Parameters:
- s- a Base64 String to be decoded.
- Returns:
- A String containing the decoded data.
- Throws:
- IllegalArgumentException- if the input is not valid Base64 encoded data.
 
- 
decodepublic static byte[] decode(char[] in) Decodes Base64 data. No blanks or line breaks are allowed within the Base64 encoded data.- Parameters:
- in- a character array containing the Base64 encoded data.
- Returns:
- An array containing the decoded data bytes.
- Throws:
- IllegalArgumentException- if the input is not valid Base64 encoded data.
 
 
-