org.apache.lucene.util

## Class RoaringDocIdSet.Builder

- java.lang.Object
- - org.apache.lucene.util.RoaringDocIdSet.Builder

- Enclosing class:
    RoaringDocIdSet

      public static class RoaringDocIdSet.Builder
      extends Object

  A builder of `RoaringDocIdSet`s.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Builder(int maxDoc)` Sole constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `RoaringDocIdSet.Builder` | `add(DocIdSetIterator disi)` Add the content of the provided `DocIdSetIterator`.
    `RoaringDocIdSet.Builder` | `add(int docId)` Add a new doc-id to this builder.
    `RoaringDocIdSet` | `build()` Build an instance.

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

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

- - ### Constructor Detail

    - #### Builder

          public Builder(int maxDoc)

      Sole constructor.

  - ### Method Detail

    - #### add

          public RoaringDocIdSet.Builder add(int docId)

      Add a new doc-id to this builder. NOTE: doc ids must be added in order.

    - #### add

          public RoaringDocIdSet.Builder add(DocIdSetIterator disi)
                                      throws IOException

      Add the content of the provided `DocIdSetIterator`.
      Throws:
        `IOException`

    - #### build

          public RoaringDocIdSet build()

      Build an instance.

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