public class SpellingTerm
extends atg.search.routing.command.SearchXMLObject
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
protected int |
mLength |
protected int |
mOffset |
protected java.util.List<Suggestion> |
mSuggestions |
protected java.lang.String |
mText |
| Constructor and Description |
|---|
SpellingTerm() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object pObject) |
protected void |
getAttributeXML(java.lang.StringBuilder sb) |
protected void |
getBodyXML(java.lang.StringBuilder sb) |
int |
getLength()
Get term length used in the initial query.
|
int |
getOffset()
Get term offset in the initial query.
|
java.lang.String |
getRequestTag() |
java.util.List<Suggestion> |
getSuggestions()
Get spell checker suggestions as a List of Strings.
|
java.lang.String |
getText()
Get spell checker initial text.
|
int |
hashCode() |
static boolean |
isAlternateTermUsed(java.lang.String pSuggestion)
Indicates whether the term is an alternate term
|
protected static boolean |
isFlag(java.lang.String pSuggestion)
Helper method for parsing that returns true when the suggestions starts with an underscore '_'
|
static boolean |
isUnknown(java.lang.String pSuggestion)
Indicates whether the term is an unknown
|
static boolean |
isUnsearchable(java.lang.String pSuggestion)
Indicates whether the term is searchable
|
void |
setLength(int pLength)
Sets the length
|
void |
setOffset(int pOffset)
Sets the offset
|
void |
setSuggestions(java.util.List<Suggestion> pSuggestions)
Sets the List of String suggestions
|
void |
setText(java.lang.String pText)
Sets the text
|
appendComplexXml, appendOptionalAttr, appendOptionalElem, appendOptionalElem, appendOptionalElem, appendOptionalValue, appendRequiredAttr, appendRequiredElem, appendRequiredElem, appendRequiredValue, getAllAttributeXML, getAllBodyXML, getDefaultXmlBytes, getParentXMLObject, getXmlPath, isPrintedFirstChild, setParentXMLObject, setPrintedFirstChild, toString, toXML, toXMLpublic static java.lang.String CLASS_VERSION
protected int mOffset
protected int mLength
protected java.util.List<Suggestion> mSuggestions
protected java.lang.String mText
public boolean equals(java.lang.Object pObject)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectprotected static boolean isFlag(java.lang.String pSuggestion)
pSuggestion - public static boolean isUnknown(java.lang.String pSuggestion)
pSuggestion - one of the spelling term suggestions. See getSuggestions()public static boolean isUnsearchable(java.lang.String pSuggestion)
pSuggestion - one of the spelling term suggestions. See getSuggestions()public static boolean isAlternateTermUsed(java.lang.String pSuggestion)
pSuggestion - one of the spelling term suggestions. See getSuggestions()public java.util.List<Suggestion> getSuggestions()
isUnknown(String),
isUnsearchable(String), and isAlternateTermUsed(String)public java.lang.String getText()
public int getOffset()
public int getLength()
public void setOffset(int pOffset)
pOffset - the offsetpublic void setLength(int pLength)
pLength - the lengthpublic void setSuggestions(java.util.List<Suggestion> pSuggestions)
pSuggestions - List of String suggestionspublic void setText(java.lang.String pText)
pText - the textpublic java.lang.String getRequestTag()
getRequestTag in class atg.search.routing.command.SearchXMLObjectprotected void getAttributeXML(java.lang.StringBuilder sb)
throws atg.search.routing.command.IncompleteCommandException
getAttributeXML in class atg.search.routing.command.SearchXMLObjectatg.search.routing.command.IncompleteCommandExceptionprotected void getBodyXML(java.lang.StringBuilder sb)
throws atg.search.routing.command.IncompleteCommandException
getBodyXML in class atg.search.routing.command.SearchXMLObjectatg.search.routing.command.IncompleteCommandException