public abstract class IndexOutput extends DataOutput implements java.io.Closeable
DataOutput for appending data to a file in a Directory.
Instances of this class are not thread-safe.Directory,
IndexInput| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
name
Just the name part from
resourceDescription |
private java.lang.String |
resourceDescription
Full description of this output, e.g.
|
| Modifier | Constructor and Description |
|---|---|
protected |
IndexOutput(java.lang.String resourceDescription,
java.lang.String name)
Sole constructor.
|
| Modifier and Type | Method and Description |
|---|---|
abstract void |
close()
Closes this stream to further operations.
|
abstract long |
getChecksum()
Returns the current checksum of bytes written so far
|
abstract long |
getFilePointer()
Returns the current position in this file, where the next write will
occur.
|
java.lang.String |
getName()
Returns the name used to create this
IndexOutput. |
java.lang.String |
toString() |
copyBytes, writeByte, writeBytes, writeBytes, writeInt, writeLong, writeMapOfStrings, writeSetOfStrings, writeShort, writeString, writeVInt, writeVLong, writeZInt, writeZLongprivate final java.lang.String resourceDescription
FSIndexOutput, and the full path to the fileprivate final java.lang.String name
resourceDescriptionprotected IndexOutput(java.lang.String resourceDescription,
java.lang.String name)
toString().public java.lang.String getName()
IndexOutput. This is especially useful when using
Directory.createTempOutput(java.lang.String, java.lang.String, org.apache.lucene.store.IOContext).public abstract void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseablejava.io.IOExceptionpublic abstract long getFilePointer()
public abstract long getChecksum()
throws java.io.IOException
java.io.IOExceptionpublic java.lang.String toString()
toString in class java.lang.Object