util
Class Base64
java.lang.Object
util.Base64
public class Base64
- extends java.lang.Object
Method Summary |
static byte[] |
decode(java.lang.String s)
Decodes the given Base64 encoded String to a new byte array. |
static void |
decode(java.lang.String s,
java.io.OutputStream os)
|
static java.lang.String |
encode(byte[] data)
|
static java.lang.StringBuffer |
encode(byte[] data,
int start,
int len,
java.lang.StringBuffer buf)
Encodes the part of the given byte array denoted by start and
len to the Base64 format. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Base64
public Base64()
encode
public static java.lang.String encode(byte[] data)
encode
public static java.lang.StringBuffer encode(byte[] data,
int start,
int len,
java.lang.StringBuffer buf)
- Encodes the part of the given byte array denoted by start and
len to the Base64 format. The encoded data is appended to the
given StringBuffer. If no StringBuffer is given, a new one is
created automatically. The StringBuffer is the return value of
this method.
decode
public static byte[] decode(java.lang.String s)
- Decodes the given Base64 encoded String to a new byte array.
The byte array holding the decoded data is returned.
decode
public static void decode(java.lang.String s,
java.io.OutputStream os)
throws java.io.IOException
- Throws:
java.io.IOException