FSDirectory.FSIndexOutput (Lucene 3.6.2 API)
Keywords: org.apache.lucene.store.FSDirectory.FSIndexOutput class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.lucene.store
Class FSDirectory.FSIndexOutput

    java.lang.Object
      org.apache.lucene.store.DataOutput
          org.apache.lucene.store.IndexOutput
              org.apache.lucene.store.BufferedIndexOutput
                  org.apache.lucene.store.FSDirectory.FSIndexOutput

All Implemented Interfaces:
  Closeable

Enclosing class:
  FSDirectory

    protected static class FSDirectory.FSIndexOutput

extends BufferedIndexOutput

Constructor Summary
`FSDirectory.FSIndexOutput(FSDirectory parent, String name)`

Method Summary
`void` | `close()` Closes this stream to further operations.
`void` | `flushBuffer(byte[] b, int offset, int size)` output methods:
`long` | `length()` The number of bytes in the file.
`void` | `seek(long pos)` Random-access methods
`void` | `setLength(long length)` Set the file length.

Methods inherited from class org.apache.lucene.store.BufferedIndexOutput
`flush, getFilePointer, writeByte, writeBytes`

Methods inherited from class org.apache.lucene.store.DataOutput
`copyBytes, writeBytes, writeChars, writeChars, writeInt, writeLong, writeShort, writeString, writeStringStringMap, writeVInt, writeVLong`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### FSDirectory.FSIndexOutput

    public FSDirectory.FSIndexOutput(FSDirectory parent,
                                     String name)
                              throws IOException

Throws:
  `IOException`

Method Detail

### flushBuffer

    public void flushBuffer(byte[] b,
                            int offset,
                            int size)
                     throws IOException

  output methods:

  Specified by:
    `flushBuffer` in class `BufferedIndexOutput`
  Parameters:
    `b` - the bytes to write
    `offset` - the offset in the byte array
    `size` - the number of bytes to write
  Throws:
    `IOException`

### close

    public void close()
               throws IOException

  Description copied from class: `BufferedIndexOutput`
  Closes this stream to further operations.

  Specified by:
    `close` in interface `Closeable`
  Overrides:
    `close` in class `BufferedIndexOutput`
  Throws:
    `IOException`

### seek

    public void seek(long pos)
              throws IOException

  Random-access methods

  Overrides:
    `seek` in class `BufferedIndexOutput`
  Throws:
    `IOException`
  See Also:
    `BufferedIndexOutput.getFilePointer()`

### length

    public long length()
                throws IOException

  Description copied from class: `BufferedIndexOutput`
  The number of bytes in the file.

  Specified by:
    `length` in class `BufferedIndexOutput`
  Throws:
    `IOException`

### setLength

    public void setLength(long length)
                   throws IOException

  Description copied from class: `IndexOutput`
  Set the file length. By default, this method does nothing (it's optional for a Directory to implement it). But, certain Directory implementations (for example @see FSDirectory) can use this to inform the underlying IO system to pre-allocate the file to the specified size. If the length is longer than the current file length, the bytes added to the file are undefined. Otherwise the file is truncated.

  Overrides:
    `setLength` in class `IndexOutput`
  Parameters:
    `length` - file length
  Throws:
    `IOException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD