opendap.servlet
Class DummySink
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
java.util.zip.DeflaterOutputStream
opendap.servlet.DummySink
- All Implemented Interfaces:
- Closeable, Flushable
public class DummySink
- extends DeflaterOutputStream
The Servlet to exercise what's available.
- Author:
- Nathan David Potter
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DummySink
public DummySink(OutputStream out,
Deflater def,
int size)
- Creates a new output stream with the specified compressor and
buffer size.
- Parameters:
out
- the output streamdef
- the compressor ("deflater")
- Throws:
IllegalArgumentException
- if size is <= 0
DummySink
public DummySink(OutputStream out,
Deflater def)
- Creates a new output stream with the specified compressor and
a default buffer size.
- Parameters:
out
- the output streamdef
- the compressor ("deflater")
DummySink
public DummySink(OutputStream out)
- Creates a new output stream with a defaul compressor and buffer size.
close
public void close()
- Specified by:
close
in interface Closeable
- Overrides:
close
in class DeflaterOutputStream
flush
public void flush()
- Specified by:
flush
in interface Flushable
- Overrides:
flush
in class FilterOutputStream
write
public void write(int b)
throws IOException
- Overrides:
write
in class DeflaterOutputStream
- Throws:
IOException
write
public void write(byte[] b,
int off,
int len)
throws IOException
- Writes an array of bytes to the compressed output stream. This
method will block until all the bytes are written.
- Overrides:
write
in class DeflaterOutputStream
- Parameters:
off
- the start offset of the datalen
- the length of the data
- Throws:
IOException
- if an I/O error has occurred
getCount
public int getCount()
setCount
public void setCount(int c)
resetCount
public void resetCount()
Copyright © 1999-2011 UCAR/Unidata. All Rights Reserved.