|
Terrier IR Platform 2.2.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.gla.terrier.compression.BitOutputStream
uk.ac.gla.terrier.compression.OldBitOutputStream
public class OldBitOutputStream
This class creates sequentially a BitFile file from a stream.
BitFile| Constructor Summary | |
|---|---|
OldBitOutputStream(java.io.File file)
Deprecated. Constructs an instance of the class for a given file |
|
OldBitOutputStream(java.io.OutputStream is)
Deprecated. Constructs an instance of the class for a given stream. |
|
OldBitOutputStream(java.lang.String filename)
Deprecated. Constructs an instance of the class for a given filename |
|
| Method Summary | |
|---|---|
void |
close()
Deprecated. Flushes and closes the stream. |
void |
flush()
Deprecated. Flush the underlying DataOutputStream to disk |
byte |
getBitOffset()
Deprecated. Returns the bit offset in the last byte. |
long |
getByteOffset()
Deprecated. Returns the byte offset of the stream. |
int |
writeBinary(int bitsToWrite,
int n)
Deprecated. Writes a binary integer to the already read buffer. |
int |
writeGamma(int n)
Deprecated. Writes an gamma encoded integer to the stream. |
int |
writeUnary(int n)
Deprecated. Writes a unary encoded integer to the stream. |
| Methods inherited from class uk.ac.gla.terrier.compression.BitOutputStream |
|---|
append, append, padAndFlush, writeDelta, writeGolomb, writeInt, writeInterpolativeCode, writeMinimalBinary, writeSkewedGolomb |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public OldBitOutputStream(java.io.OutputStream is)
throws java.io.IOException
is - java.io.OutputStream the underlying input stream
java.io.IOException - if an I/O error occurs
public OldBitOutputStream(java.lang.String filename)
throws java.io.IOException
filename - java.lang.String the name of the undelying file
java.io.IOException - if an I/O error occurs
public OldBitOutputStream(java.io.File file)
throws java.io.IOException
file - java.io.File the underlying file
java.io.IOException - if an I/O error occurs| Method Detail |
|---|
public int writeBinary(int bitsToWrite,
int n)
throws java.io.IOException
writeBinary in interface BitOutwriteBinary in class BitOutputStreambitsToWrite - the number of bits to use for encodingn - the integer
java.io.IOException - if an I/O error occurs.
public void close()
throws java.io.IOException
close in interface java.io.Closeableclose in class BitOutputStreamjava.io.IOException - if an I/O error occurs
public int writeUnary(int n)
throws java.io.IOException
writeUnary in interface BitOutwriteUnary in class BitOutputStreamn - int the integer to write.
java.io.IOException - if an I/O error occurs
public int writeGamma(int n)
throws java.io.IOException
writeGamma in interface BitOutwriteGamma in class BitOutputStreamn - The integer to be encoded and saved in the buffer.
java.io.IOException - if an I/O error occurspublic long getByteOffset()
getByteOffset in interface BitOutgetByteOffset in class BitOutputStreampublic byte getBitOffset()
getBitOffset in interface BitOutgetBitOffset in class BitOutputStreampublic void flush()
flush in class BitOutputStream
|
Terrier IR Platform 2.2.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||