org.apache.batik.util

Class Base64EncoderStream

public class Base64EncoderStream extends OutputStream

This class implements a Base64 Character encoder as specified in RFC1113. Unlike some other encoding schemes there is nothing in this encoding that indicates where a buffer starts or ends. This means that the encoded text will simply start with the first line of encoded text and end with the last line of encoded text.
Constructor Summary
Base64EncoderStream(OutputStream out)
Base64EncoderStream(OutputStream out, boolean closeOutOnClose)
Method Summary
voidclose()
voidflush()
This can't really flush out output since that may generate '=' chars which would indicate the end of the stream.
voidwrite(int b)
voidwrite(byte[] data)
voidwrite(byte[] data, int off, int len)

Constructor Detail

Base64EncoderStream

public Base64EncoderStream(OutputStream out)

Base64EncoderStream

public Base64EncoderStream(OutputStream out, boolean closeOutOnClose)

Method Detail

close

public void close()

flush

public void flush()
This can't really flush out output since that may generate '=' chars which would indicate the end of the stream. Instead we flush out. You can only be sure all output is writen by closing this stream.

write

public void write(int b)

write

public void write(byte[] data)

write

public void write(byte[] data, int off, int len)
Copyright B) 2008 Apache Software Foundation. All Rights Reserved.