net.spy.util
Class Base64

java.lang.Object
  extended by net.spy.util.Base64

public class Base64
extends java.lang.Object

Base64 block encoder/decoder.


Constructor Summary
Base64()
          Get a base64 encode/decoder.
 
Method Summary
 byte[] decode(java.lang.String input)
          Decode a string back into the bytes.
 java.lang.String encode(byte[] data)
          Encode some bytes to a base64 string.
static Base64 getInstance()
          Get the singleton base64 instance.
 boolean isValidBase64Char(char c)
          Is this character a valid Base64 character?
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Base64

public Base64()
Get a base64 encode/decoder.

Method Detail

getInstance

public static Base64 getInstance()
Get the singleton base64 instance.


encode

public java.lang.String encode(byte[] data)
Encode some bytes to a base64 string.


decode

public byte[] decode(java.lang.String input)
Decode a string back into the bytes.


isValidBase64Char

public boolean isValidBase64Char(char c)
Is this character a valid Base64 character?

Returns:
true if this character is in our Base64 character map.


Copyright © 1995-2007 SPY Internetworking. All Rights Reserved.