public class MatchFilterTokenProperty extends MatchFilter
Constructor and Description |
---|
MatchFilterTokenProperty(String label,
String propertyName) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
ConstraintValue |
evaluate(ForwardIndexDocument fiDoc,
Span[] capturedGroups)
Evaluate the constraint at the current match position.
|
String |
getGroupName() |
String |
getPropertyName() |
int |
hashCode() |
boolean |
hasProperty() |
void |
lookupAnnotationIndices(ForwardIndexAccessor fiAccessor)
Let token annotation nodes look up the index of their annotation
|
MatchFilter |
matchOtherTokenSameProperty(String otherGroupName,
MatchSensitivity sensitivity) |
MatchFilter |
matchTokenString(String str,
MatchSensitivity sensitivity) |
MatchFilter |
rewrite()
Try to rewrite this filter into a more efficient version
|
void |
setHitQueryContext(HitQueryContext context)
Pass the hit query context object to this constraint, so we can look up the
group numbers we need.
|
String |
toString() |
public String toString()
toString
in class MatchFilter
public int hashCode()
hashCode
in class MatchFilter
public boolean equals(Object obj)
equals
in class MatchFilter
public void setHitQueryContext(HitQueryContext context)
MatchFilter
setHitQueryContext
in class MatchFilter
context
- hit query context objectpublic ConstraintValue evaluate(ForwardIndexDocument fiDoc, Span[] capturedGroups)
MatchFilter
evaluate
in class MatchFilter
fiDoc
- document we're matching in right nowcapturedGroups
- current captured groups statepublic void lookupAnnotationIndices(ForwardIndexAccessor fiAccessor)
MatchFilter
lookupAnnotationIndices
in class MatchFilter
fiAccessor
- forward index accessorpublic MatchFilter rewrite()
MatchFilter
rewrite
in class MatchFilter
public MatchFilter matchTokenString(String str, MatchSensitivity sensitivity)
public MatchFilter matchOtherTokenSameProperty(String otherGroupName, MatchSensitivity sensitivity)
public boolean hasProperty()
public String getPropertyName()
public String getGroupName()
Copyright © 2020 Instituut voor Nederlandse Taal (INT). All rights reserved.