|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.niocchi.core.Base64Coder
public class Base64Coder
A Base64 Encoder/Decoder.
This class is used to encode and decode data in Base64 format as described in RFC 1521.
Home page: www.source-code.biz
Author: Christian d'Heureuse, Inventec Informatik AG, Zurich, Switzerland
Multi-licensed: EPL/LGPL/AL/BSD.
Version history:
2003-07-22 Christian d'Heureuse (chdh): Module created.
2005-08-11 chdh: Lincense changed from GPL to LGPL.
2006-11-21 chdh:
Method encode(String) renamed to encodeString(String).
Method decode(String) renamed to decodeString(String).
New method encode(byte[],int) added.
New method decode(String) added.
2009-07-16: Additional licenses (EPL/AL) added.
2009-09-16: Additional license (BSD) added.
Method Summary | |
---|---|
static byte[] |
decode(char[] in)
Decodes Base64 data. |
static java.lang.String |
decode(java.lang.String s)
Decodes a Base64 string. |
static char[] |
encode(byte[] in)
Encodes a byte array into Base64 format. |
static java.lang.String |
encode(java.lang.String s)
Encodes a string into Base64 format. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static java.lang.String encode(java.lang.String s)
s
- a String to be encoded.
public static char[] encode(byte[] in)
in
- an array containing the data bytes to be encoded.
public static java.lang.String decode(java.lang.String s)
s
- a Base64 String to be decoded.
java.lang.IllegalArgumentException
- if the input is not valid Base64 encoded data.public static byte[] decode(char[] in)
in
- a character array containing the Base64 encoded data.
java.lang.IllegalArgumentException
- if the input is not valid Base64 encoded data.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |