1 package org.apache.lucene.search.spans; 2 3 18 19 import java.io.IOException ; 20 21 import java.util.Collection ; 22 23 import org.apache.lucene.index.IndexReader; 24 import org.apache.lucene.search.Query; 25 import org.apache.lucene.search.Weight; 26 import org.apache.lucene.search.Searcher; 27 28 29 public abstract class SpanQuery extends Query { 30 32 public abstract Spans getSpans(IndexReader reader) throws IOException ; 33 34 35 public abstract String getField(); 36 37 38 public abstract Collection getTerms(); 39 40 protected Weight createWeight(Searcher searcher) throws IOException { 41 return new SpanWeight(this, searcher); 42 } 43 44 } 45 46 | Popular Tags |