public static class ConstQuery.ConstQueryExecutor extends AbstractQueryExecutor
ConstQuery
. It returns document IDs
from the predefined list, and no positions.closed, engine, latestDocument, queryNode
Constructor and Description |
---|
ConstQueryExecutor(ConstQuery qNode,
QueryEngine engine) |
Modifier and Type | Method and Description |
---|---|
<T> T |
accept(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor<T> visitor)
Always returns null.
|
<T> T |
acceptOnTruePaths(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor<T> visitor)
Always returns null
|
it.unimi.dsi.fastutil.objects.ReferenceSet<it.unimi.di.big.mg4j.index.Index> |
indices()
Returns an empty set of indices.
|
long |
nextDocument(long greaterThan)
Gets the next document that contains a match, with a document ID greater
than the ID provided in the
from parameter. |
Binding |
nextHit()
This query executor type does not support positions, so it always returns
null.
|
close, dispose, document, getLatestDocument, getQueryEngine, getQueryNode, intervalIterator, intervalIterator, intervalIterators, mayHaveNext, nextDocument, skipTo, weight, weight
public ConstQueryExecutor(ConstQuery qNode, QueryEngine engine)
public long nextDocument(long greaterThan) throws IOException
QueryExecutor
from
parameter.
This method essentially requests the query executor to skip over a number
of documents that are not desired for external reasons (e.g. when running
a complex query, other query constraints may have already removed a set of
documents from the candidate list).
The query executor will never roll back: all document IDs returned
are in ascending order. This means that if the value provided for the
greaterThan
parameter is lower than the latest document ID
returned, it will have no effect.greaterThan
- a document ID representing the lowest bound (exclusive) for
the requested document ID.greaterThan
, or -1
if no more matching documents
are found.IOException
- if the index files cannot be accessed.public Binding nextHit() throws IOException
Binding
corresponding to the root query node for this
executor. If no further matches are possible on the current document, then
null
is returned.IOException
- if the index files cannot be accessed.QueryExecutor.nextHit()
public it.unimi.dsi.fastutil.objects.ReferenceSet<it.unimi.di.big.mg4j.index.Index> indices()
DocumentIterator.indices()
public <T> T accept(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor<T> visitor) throws IOException
IOException
DocumentIterator.accept(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor)
public <T> T acceptOnTruePaths(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor<T> visitor) throws IOException
IOException
DocumentIterator.acceptOnTruePaths(it.unimi.di.big.mg4j.search.visitor.DocumentIteratorVisitor)
Copyright © 2021 GATE. All rights reserved.