org.apache.lucene.store
public abstract class OutputStream extends Object
See Also: Directory InputStream
Method Summary | |
---|---|
void | close() Closes this stream to further operations. |
protected void | flush() Forces any buffered output to be written. |
protected abstract void | flushBuffer(byte[] b, int len) Expert: implements buffer write. |
long | getFilePointer() Returns the current position in this file, where the next write will
occur. |
abstract long | length() The number of bytes in the file. |
void | seek(long pos) Sets current position in this file, where the next write will occur. |
void | writeByte(byte b) Writes a single byte. |
void | writeBytes(byte[] b, int length) Writes an array of bytes. |
void | writeChars(String s, int start, int length) Writes a sequence of UTF-8 encoded characters from a string. |
void | writeInt(int i) Writes an int as four bytes. |
void | writeLong(long i) Writes a long as eight bytes. |
void | writeString(String s) Writes a string. |
void | writeVInt(int i) Writes an int in a variable-length format. |
void | writeVLong(long i) Writes an long in a variable-length format. |
Parameters: b the bytes to write len the number of bytes to write
See Also: OutputStream
See Also: getFilePointer
See Also: readByte
Parameters: b the bytes to write length the number of bytes to write
See Also: (byte[],int,int)
Parameters: s the source of the characters start the first character in the sequence length the number of characters in the sequence
See Also: (char[],int,int)
See Also: readInt
See Also: readLong
See Also: readString
See Also: readVInt
See Also: readVLong