org.caleigo.toolkit.tunnel
Class ZipPacker.ZipPackerOutputStream

java.lang.Object
  extended byjava.io.OutputStream
      extended byjava.io.FilterOutputStream
          extended byorg.caleigo.toolkit.tunnel.ZipPacker.ZipPackerOutputStream
Enclosing class:
ZipPacker

protected class ZipPacker.ZipPackerOutputStream
extends java.io.FilterOutputStream


Field Summary
protected  int mBufferSize
           
protected  byte[] mByteBuffer
           
protected  int mCurrentPosition
           
protected  int mZipEntryID
           
protected  java.util.zip.ZipOutputStream mZipOutputStream
           
 
Fields inherited from class java.io.FilterOutputStream
out
 
Constructor Summary
ZipPacker.ZipPackerOutputStream(java.io.OutputStream out, int bufferSize)
          Creates a ZipPackerOutputStream that wrapps an OutputStream.
 
Method Summary
 void flush()
           
protected  int getNextZipEntryID()
           
 void write(int b)
           
 
Methods inherited from class java.io.FilterOutputStream
close, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mByteBuffer

protected byte[] mByteBuffer

mBufferSize

protected int mBufferSize

mCurrentPosition

protected int mCurrentPosition

mZipOutputStream

protected java.util.zip.ZipOutputStream mZipOutputStream

mZipEntryID

protected int mZipEntryID
Constructor Detail

ZipPacker.ZipPackerOutputStream

public ZipPacker.ZipPackerOutputStream(java.io.OutputStream out,
                                       int bufferSize)
Creates a ZipPackerOutputStream that wrapps an OutputStream.

Parameters:
out - the OutputStream that should be used to write the zipped data to.
bufferSize - the initial size of the internal buffer. The size of the buffer is increased as needed. Each time the buffer needs to be resized its size is increased by bufferSize / 2 bytes.
Method Detail

write

public void write(int b)
           throws java.io.IOException
Throws:
java.io.IOException

flush

public void flush()
           throws java.io.IOException
Throws:
java.io.IOException

getNextZipEntryID

protected int getNextZipEntryID()


Copyright © 2005 Caleigo. All Rights Reserved.