org.apache.lucene.codecs.lucene50

## Class Lucene50LiveDocsFormat

- java.lang.Object
- - org.apache.lucene.codecs.LiveDocsFormat
  - - org.apache.lucene.codecs.lucene50.Lucene50LiveDocsFormat

-     public final class Lucene50LiveDocsFormat
      extends LiveDocsFormat

  Lucene 5.0 live docs format

  The .liv file is optional, and only exists when a segment contains deletions.

  Although per-segment, this file is maintained exterior to compound segment files.

  Deletions (.liv) --> IndexHeader,Generation,Bits

  - SegmentHeader --> `IndexHeader`
  - Bits --> <`Int64`> LongCount

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Lucene50LiveDocsFormat()` Sole constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `files(SegmentCommitInfo info, Collection<String> files)` Records all files in use by this `SegmentCommitInfo` into the files argument.
    `Bits` | `readLiveDocs(Directory dir, SegmentCommitInfo info, IOContext context)` Read live docs bits.
    `void` | `writeLiveDocs(Bits bits, Directory dir, SegmentCommitInfo info, int newDelCount, IOContext context)` Persist live docs bits.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Lucene50LiveDocsFormat

          public Lucene50LiveDocsFormat()

      Sole constructor.

  - ### Method Detail

    - #### readLiveDocs

          public Bits readLiveDocs(Directory dir,
                                   SegmentCommitInfo info,
                                   IOContext context)
                            throws IOException

      Description copied from class: `LiveDocsFormat`
      Read live docs bits.
      Specified by:
        `readLiveDocs` in class `LiveDocsFormat`
      Throws:
        `IOException`

    - #### writeLiveDocs

          public void writeLiveDocs(Bits bits,
                                    Directory dir,
                                    SegmentCommitInfo info,
                                    int newDelCount,
                                    IOContext context)
                             throws IOException

      Description copied from class: `LiveDocsFormat`
      Persist live docs bits. Use `SegmentCommitInfo.getNextDelGen()` to determine the generation of the deletes file you should write to.
      Specified by:
        `writeLiveDocs` in class `LiveDocsFormat`
      Throws:
        `IOException`

    - #### files

          public void files(SegmentCommitInfo info,
                            Collection<String> files)
                     throws IOException

      Description copied from class: `LiveDocsFormat`
      Records all files in use by this `SegmentCommitInfo` into the files argument.
      Specified by:
        `files` in class `LiveDocsFormat`
      Throws:
        `IOException`

Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.