|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.unimi.dsi.mg4j.search.IntervalIterators
A class providing static methods and objects that do useful things with interval iterators.
Nested Class Summary | |
static class |
IntervalIterators.EmptyIntervalIterator
An iterator returning no intervals. |
static class |
IntervalIterators.FakeIterator
An iterator that throws an exception on all method calls, except for IntervalIterators.FakeIterator.hasNext() ,
which has a settable value. |
Field Summary | |
static IntervalIterators.EmptyIntervalIterator |
EMPTY_ITERATOR
|
static IntervalIterator |
FALSE
An iterator representing absolute falseness. |
static IntervalIterator |
TRUE
An iterator representing absolute truth. |
Method Summary | |
static double |
clarkeCormackScore(IntervalIterator it)
Computes the Clarke-Cormack score using the default values for parameter ( h =16 and alpha =1). |
static double |
clarkeCormackScore(IntervalIterator it,
double alpha,
int h)
Computes the Clarke-Cormack score of a document. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final IntervalIterators.EmptyIntervalIterator EMPTY_ITERATOR
public static final IntervalIterator TRUE
When this iterator is returned by a subquery on a given index, this means that the index has no part in the construction of the result, but that, at the same time, the result is true.
For example, consider the query (foo OR title:bar) AND fee evaluated on
a document which contains bar in the title index, but not foo in the
primary index, and which moreover contains fee in the primary index. The subquery
(foo OR title:bar) has value TRUE
on the primary index, as there is nothing
to be returned, but the subquery is nonetheless true.
public static final IntervalIterator FALSE
When this iterator is returned by a subquery on a given index, this means that the subquery is false.
For example, consider the query (foo AND title:bar) OR fee evaluated on
a document which contains bar in the title index, but not foo in the
primary index, and which moreover contains fee in the primary index. The subquery
(foo AND title:bar) has value FALSE
on both the primary and the title index.
Method Detail |
public static final double clarkeCormackScore(IntervalIterator it, double alpha, int h)
it
- the iterator; note that the iterator gets exhausted by this call.alpha
- the parameter used in the computation of the score.h
- the parameter used in the computation of the score.
ClarkeCormackScorer
public static final double clarkeCormackScore(IntervalIterator it)
h
=16 and alpha
=1).
it
- the iterator; note that the iterator gets exhausted by this call.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |