| java.lang.Object de.mcs.utils.codecs.Base64Decoder
Method Summary | |
public static byte[] | decode(String string) decode mime string to byte array. | public static void | main(String[] args) Test the decoder. | final public void | process() Do the actual decoding. | final public String | processString() Do the decoding, and return a String. |
Base64Decoder | public Base64Decoder(String input)(Code) | | Constructor for Base64Decoder.
Parameters: input - String |
Base64Decoder | public Base64Decoder(String input, String sEncoding)(Code) | | Create a decoder to decode a String.
Parameters: input - The string to be decoded. Parameters: sEncoding - String |
Base64Decoder | public Base64Decoder(InputStream isIn, OutputStream isOut)(Code) | | Create a decoder to decode a stream.
Parameters: isIn - The input stream (to be decoded). Parameters: isOut - The output stream, to write decoded data to. |
decode | public static byte[] decode(String string) throws Exception(Code) | | decode mime string to byte array.
Parameters: string - the string to decode byte[] throws: Exception - if something goes wrong |
main | public static void main(String[] args)(Code) | | Test the decoder. Run it with one argument: the string to be decoded, it
will print out the decoded value.
Parameters: args - String[] |
process | final public void process() throws Exception(Code) | | Do the actual decoding. Process the input stream by decoding it and
emiting the resulting bytes into the output stream. exception IOException
If the input or output stream accesses failed.
exception: Exception - If the input stream is not compliant with the BASE64specification. |
processString | final public String processString()(Code) | | Do the decoding, and return a String. This methods should be called when
the decoder is used in String mode. It decodes the input
string to an output string that is returned.
String exception RuntimeException If the object wasn'tconstructed to decode a String. |
|
|