kiwi.io
Class Radix64InputStream

java.lang.Object
  |
  +--java.io.InputStream
        |
        +--java.io.FilterInputStream
              |
              +--kiwi.io.Radix64InputStream

public class Radix64InputStream
extends FilterInputStream

This class implements a Radix-64 decoding filter. It reads Radix-64 encoded data from its input stream and outputs the original (decoded) form of the data. To decode a file encoded in Radix-64, one would do something like the following:

 File f = new File("encoded.txt");
 Radix64InputStream r64in = new Radix64InputStream(new FileInputStream(f));
 

The decoded data may then be obtained by reading from r64in.

This filter disregards any non-Radix-64 characters in the input. Radix-64 characters include '/', '+', '=', 'A' - 'Z', '0' - '9', and 'a' - 'z'.

Version:
1.0 (10/98)
Author:
Mark Lindner, PING Software Group
See Also:
FilterInputStream

Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
Radix64InputStream(InputStream in)
          Construct a new Radix64InputStream to filter the given input stream.
 
Method Summary
 int read()
          Read a byte from the input stream.
 
Methods inherited from class java.io.FilterInputStream
available, close, mark, markSupported, read, read, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Radix64InputStream

public Radix64InputStream(InputStream in)
Construct a new Radix64InputStream to filter the given input stream.
Parameters:
in - The InputStream to filter.
Method Detail

read

public int read()
         throws IOException
Read a byte from the input stream.
Returns:
The next (decoded) byte.
Overrides:
read in class FilterInputStream