public abstract class

BufferedIndexOutput

extends IndexOutput
java.lang.Object
   ↳ org.apache.lucene.store.IndexOutput
     ↳ org.apache.lucene.store.BufferedIndexOutput
Known Direct Subclasses

Class Overview

Base implementation class for buffered IndexOutput.

Summary

Public Constructors
BufferedIndexOutput()
Public Methods
void close()
Closes this stream to further operations.
void flush()
Forces any buffered output to be written.
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 offset, int length)
Writes an array of bytes.
Protected Methods
abstract void flushBuffer(byte[] b, int offset, int len)
Expert: implements buffer write.
[Expand]
Inherited Methods
From class org.apache.lucene.store.IndexOutput
From class java.lang.Object
From interface java.io.Closeable

Public Constructors

public BufferedIndexOutput ()

Public Methods

public void close ()

Closes this stream to further operations.

Throws
IOException

public void flush ()

Forces any buffered output to be written.

Throws
IOException

public long getFilePointer ()

Returns the current position in this file, where the next write will occur.

See Also

public abstract long length ()

The number of bytes in the file.

Throws
IOException

public void seek (long pos)

Sets current position in this file, where the next write will occur.

Throws
IOException
See Also

public void writeByte (byte b)

Writes a single byte.

Throws
IOException
See Also

public void writeBytes (byte[] b, int offset, int length)

Writes an array of bytes.

Parameters
b the bytes to write
offset the offset in the byte array
length the number of bytes to write
Throws
IOException

Protected Methods

protected abstract void flushBuffer (byte[] b, int offset, int len)

Expert: implements buffer write. Writes bytes at the current position in the output.

Parameters
b the bytes to write
offset the offset in the byte array
len the number of bytes to write
Throws
IOException