public class WeightedSpanTerm extends WeightedTerm
| Constructor and Description |
|---|
WeightedSpanTerm(float weight,
String term) |
WeightedSpanTerm(float weight,
String term,
boolean positionSensitive) |
| Modifier and Type | Method and Description |
|---|---|
void |
addPositionSpans(List<PositionSpan> positionSpans) |
boolean |
checkPosition(int position)
Checks to see if this term is valid at
position. |
List<PositionSpan> |
getPositionSpans() |
boolean |
isPositionSensitive() |
void |
setPositionSensitive(boolean positionSensitive) |
getTerm, getWeight, setTerm, setWeightpublic WeightedSpanTerm(float weight,
String term)
weight - term - public WeightedSpanTerm(float weight,
String term,
boolean positionSensitive)
weight - term - positionSensitive - public boolean checkPosition(int position)
position.position - to check against valid term positionspublic void addPositionSpans(List<PositionSpan> positionSpans)
public boolean isPositionSensitive()
public void setPositionSensitive(boolean positionSensitive)
public List<PositionSpan> getPositionSpans()