Example usage for org.apache.lucene.search ConjunctionDISI intersectSpans

List of usage examples for org.apache.lucene.search ConjunctionDISI intersectSpans

Introduction

In this page you can find the example usage for org.apache.lucene.search ConjunctionDISI intersectSpans.

Prototype

public static DocIdSetIterator intersectSpans(List<Spans> spanList) 

Source Link

Document

Create a conjunction over the provided Spans .

Usage

From source file:uk.co.flax.luwak.util.XConjunctionSpans.java

License:Apache License

XConjunctionSpans(List<Spans> subSpans) {
    if (subSpans.size() < 2) {
        throw new IllegalArgumentException("Less than 2 subSpans.size():" + subSpans.size());
    }//  w w w.j a  v a2  s .  com
    this.subSpans = subSpans.toArray(new Spans[subSpans.size()]);
    this.conjunction = ConjunctionDISI.intersectSpans(subSpans);
    this.atFirstInCurrentDoc = true; // ensure for doc -1 that start/end positions are -1
}