public final class AnchorFilter extends Phrase
Modifier and Type | Class and Description |
---|---|
static class |
AnchorFilter.AnchorMode
Mode for anchoring this term to indexed values
|
Phrase.Parameter
parameters
Constructor and Description |
---|
AnchorFilter()
Constructor.
|
AnchorFilter(AnchorFilter.AnchorMode mode,
Phrase phrase)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
AnchorFilter |
clone() |
static AnchorFilter |
endswith(Phrase phrase) |
boolean |
equals(Object other) |
static AnchorFilter |
equals(Phrase phrase) |
int |
getEndOffset()
Get the end offset (0 indexed, exclusive) for this term in the original query string.
|
AnchorFilter.AnchorMode |
getMode()
Get the mode for anchoring
phrase . |
Phrase |
getPhrase()
Get the phrase anchor filtering will be applied to.
|
int |
getStartOffset()
Get the start offset (0 indexed, inclusive) for this term in the original query string.
|
int |
hashCode() |
Phrase |
rewrite(PhraseHandler handler)
Recursively rewrite this phrase using
handler . |
Phrase |
rewriteChildren(PhraseHandler handler)
Rewrite any children of this phrase using
handler . |
void |
setMode(AnchorFilter.AnchorMode value)
Set the mode for anchoring
phrase . |
void |
setPhrase(Phrase value)
Set the phrase anchor filtering will be applied to.
|
static AnchorFilter |
startswith(Phrase phrase) |
void |
toString(StringBuilder buffer,
boolean compact)
Appends the string representation of this query to
buffer . |
containsParameters, containsParameters, copyParameters, getBoost, getParameter, getParameter, getParameter, getParameter, getParameterInternal, isMatchAll, parameters, parseIntParameter, removeParameter, setBoost, setParameter, setParameters, toArray, toString, toString
public AnchorFilter()
public AnchorFilter(AnchorFilter.AnchorMode mode, Phrase phrase)
public int getStartOffset()
This value is set during parsing and indicates the start offset into the original query string that this term represents. In general, offsets should not be set/modified by query transformers and it is recommended that start and end offsets are set to zero when cloning.
NOTE: if Phrase.getStartOffset()
== Phrase.getEndOffset()
, this indicates that the term did not come from a parsed query string.
getStartOffset
in class Phrase
public int getEndOffset()
This value is set during parsing and indicates the end offset of the original query string that this term represents. In general, offsets should not be set/modified by query transformers and it is recommended that start and end offsets are set to zero when cloning.
NOTE: if Phrase.getStartOffset()
== Phrase.getEndOffset()
, this indicates that the term did not come from a parsed query string.
getEndOffset
in class Phrase
public AnchorFilter.AnchorMode getMode()
phrase
.public void setMode(AnchorFilter.AnchorMode value)
phrase
.public Phrase getPhrase()
public void setPhrase(Phrase value)
public Phrase rewrite(PhraseHandler handler)
handler
.
NOTE: If a phrase has any children, the phrase itself will be passed to handler
first, prior to its children.
If handler
returns a new phrase, its children will not be traversed automatically.
public Phrase rewriteChildren(PhraseHandler handler)
handler
.
Returns the modified phrase, which may be null
if all children were removed by handler
.
This method may have no effect if this Phrase
represents a leaf in the tree.
NOTE: child phrases are not recursively traversed.
rewriteChildren
in class Phrase
public AnchorFilter clone()
public void toString(StringBuilder buffer, boolean compact)
buffer
.public static AnchorFilter equals(Phrase phrase)
public static AnchorFilter startswith(Phrase phrase)
public static AnchorFilter endswith(Phrase phrase)
Copyright © 2018 Attivio, Inc. All Rights Reserved.
PATENT NOTICE: Attivio, Inc. Software Related Patents. With respect to the Attivio software product(s) being used, the following patents apply: Querying Joined Data Within A Search Engine Index: United States Patent No.(s): 8,073,840. Ordered Processing of Groups of Messages: U.S. Patent No.(s) 8,495,656. Signal processing approach to sentiment analysis for entities in documents: U.S. Patent No.(s) 8,725,494. Other U.S. and International Patents Pending.