public class InstantiatedTermPositionVector extends InstantiatedTermFreqVector implements TermPositionVector, Serializable
InstantiatedIndexReader
.TermPositionVector
,
Serialized FormConstructor and Description |
---|
InstantiatedTermPositionVector(InstantiatedDocument document,
String field) |
Modifier and Type | Method and Description |
---|---|
TermVectorOffsetInfo[] |
getOffsets(int index)
Returns an array of TermVectorOffsetInfo in which the term is found.
|
int[] |
getTermPositions(int index)
Returns an array of positions in which the term is found.
|
getField, getTermDocumentInformations, getTermFrequencies, getTerms, indexesOf, indexOf, size, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getField, getTermFrequencies, getTerms, indexesOf, indexOf, size
public InstantiatedTermPositionVector(InstantiatedDocument document, String field)
public int[] getTermPositions(int index)
TermPositionVector
indexOf
method.
May return null if positions have not been stored.getTermPositions
in interface TermPositionVector
public TermVectorOffsetInfo[] getOffsets(int index)
TermPositionVector
getOffsets
in interface TermPositionVector
index
- The position in the array to get the offsets fromToken