Class FieldPhraseList.WeightedPhraseInfo
- java.lang.Object
 - 
- org.apache.lucene.search.vectorhighlight.FieldPhraseList.WeightedPhraseInfo
 
 
- 
- All Implemented Interfaces:
 java.lang.Comparable<FieldPhraseList.WeightedPhraseInfo>
- Enclosing class:
 - FieldPhraseList
 
public static class FieldPhraseList.WeightedPhraseInfo extends java.lang.Object implements java.lang.Comparable<FieldPhraseList.WeightedPhraseInfo>
Represents the list of term offsets and boost for some text 
- 
- 
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFieldPhraseList.WeightedPhraseInfo.ToffsTerm offsets (start + end) 
- 
Constructor Summary
Constructors Constructor Description WeightedPhraseInfo(java.util.Collection<FieldPhraseList.WeightedPhraseInfo> toMerge)Merging constructor.WeightedPhraseInfo(java.util.LinkedList<FieldTermStack.TermInfo> terms, float boost)WeightedPhraseInfo(java.util.LinkedList<FieldTermStack.TermInfo> terms, float boost, int seqnum) 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(FieldPhraseList.WeightedPhraseInfo other)booleanequals(java.lang.Object obj)floatgetBoost()intgetEndOffset()intgetSeqnum()intgetStartOffset()java.util.List<FieldTermStack.TermInfo>getTermsInfos()java.util.List<FieldPhraseList.WeightedPhraseInfo.Toffs>getTermsOffsets()java.lang.StringgetText()Text of the match, calculated on the fly.inthashCode()booleanisOffsetOverlap(FieldPhraseList.WeightedPhraseInfo other)java.lang.StringtoString() 
 - 
 
- 
- 
Constructor Detail
- 
WeightedPhraseInfo
public WeightedPhraseInfo(java.util.LinkedList<FieldTermStack.TermInfo> terms, float boost)
 
- 
WeightedPhraseInfo
public WeightedPhraseInfo(java.util.LinkedList<FieldTermStack.TermInfo> terms, float boost, int seqnum)
 
- 
WeightedPhraseInfo
public WeightedPhraseInfo(java.util.Collection<FieldPhraseList.WeightedPhraseInfo> toMerge)
Merging constructor. Note that this just grabs seqnum from the first info. 
 - 
 
- 
Method Detail
- 
getText
public java.lang.String getText()
Text of the match, calculated on the fly. Use for debugging only.- Returns:
 - the text
 
 
- 
getTermsOffsets
public java.util.List<FieldPhraseList.WeightedPhraseInfo.Toffs> getTermsOffsets()
- Returns:
 - the termsOffsets
 
 
- 
getBoost
public float getBoost()
- Returns:
 - the boost
 
 
- 
getTermsInfos
public java.util.List<FieldTermStack.TermInfo> getTermsInfos()
- Returns:
 - the termInfos
 
 
- 
getStartOffset
public int getStartOffset()
 
- 
getEndOffset
public int getEndOffset()
 
- 
isOffsetOverlap
public boolean isOffsetOverlap(FieldPhraseList.WeightedPhraseInfo other)
 
- 
toString
public java.lang.String toString()
- Overrides:
 toStringin classjava.lang.Object
 
- 
getSeqnum
public int getSeqnum()
- Returns:
 - the seqnum
 
 
- 
compareTo
public int compareTo(FieldPhraseList.WeightedPhraseInfo other)
- Specified by:
 compareToin interfacejava.lang.Comparable<FieldPhraseList.WeightedPhraseInfo>
 
- 
hashCode
public int hashCode()
- Overrides:
 hashCodein classjava.lang.Object
 
- 
equals
public boolean equals(java.lang.Object obj)
- Overrides:
 equalsin classjava.lang.Object
 
 - 
 
 -