it.sauronsoftware.base64
Class Base64InputStream

java.lang.Object
  extended by java.io.InputStream
      extended by it.sauronsoftware.base64.Base64InputStream
All Implemented Interfaces:
java.io.Closeable

public class Base64InputStream
extends java.io.InputStream

A base64 encoding input stream.

A Base64InputStream reads from an underlying stream which is supposed to be a base64 encoded stream. Base64InputStream decodes the data read from the underlying stream and returns the decoded bytes to the caller.

Author:
Carlo Pelliccia

Constructor Summary
Base64InputStream(java.io.InputStream inputStream)
           It builds a base64 decoding input stream.
 
Method Summary
 void close()
           
 int read()
           
 
Methods inherited from class java.io.InputStream
available, 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

Base64InputStream

public Base64InputStream(java.io.InputStream inputStream)

It builds a base64 decoding input stream.

Parameters:
inputStream - The underlying stream, from which the encoded data is read.
Method Detail

read

public int read()
         throws java.io.IOException
Specified by:
read in class java.io.InputStream
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Specified by:
close in interface java.io.Closeable
Overrides:
close in class java.io.InputStream
Throws:
java.io.IOException