public class SQI extends SemanticProcessor implements com.exalead.util.Checkable, java.io.Serializable
SemanticProcessor.Transformer<T>, SemanticProcessor.Visitor
Modifier and Type | Field and Description |
---|---|
java.lang.String |
annotateUnusedTokensWith |
boolean |
breakOnLine |
boolean |
breakOnParagraph |
boolean |
breakOnSentence |
static boolean |
DEFAULT_BREAK_ON_LINE |
static boolean |
DEFAULT_BREAK_ON_PARAGRAPH |
static boolean |
DEFAULT_BREAK_ON_SENTENCE |
static boolean |
DEFAULT_EXPLICIT_ATOM_MATCH |
static boolean |
DEFAULT_MATCH_ALL_RULES |
static boolean |
DEFAULT_NO_OVERLAP |
boolean |
explicitAtomMatch |
boolean |
matchAllRules |
boolean |
noOverlap |
java.lang.String |
prefix |
java.lang.String |
resourceDir |
contexts, name, src
Modifier and Type | Method and Description |
---|---|
<T> T |
accept(SemanticProcessor.Transformer<T> transformer,
T[] t) |
void |
accept(SemanticProcessor.Visitor visitor) |
void |
check(boolean deep,
java.lang.String errorContext)
Checks this SQI.
|
static SQI |
fromString(java.lang.String s)
String representation of this SQI.
|
java.lang.String |
getAnnotateUnusedTokensWith()
The annotation to set on the non-matching part of the input for postprocessing
|
java.lang.String |
getPrefix()
Output annotations prefix
|
java.lang.String |
getResourceDir()
URL for the resource (data://, file:// or resource://)
|
boolean |
isBreakOnLine()
If true: maximum one match per line, no match inter-line.
|
boolean |
isBreakOnParagraph()
If true: maximum one match per paragraph, no match inter-paragraph.
|
boolean |
isBreakOnSentence()
If true: maximum one match per sentence, no match inter-sentence.
(will add SentenceFinder automatically). |
boolean |
isExplicitAtomMatch()
If set to true, add extra annotations where named atoms have matched.
|
boolean |
isMatchAllRules()
If set to true, return the full list of matched rule.
If false, return only the first matched rule. |
boolean |
isNoOverlap()
If set to true, don't report overlapping matches, keep the leftmost longest.
|
SQI |
makeCopy()
Creates and returns a deep copy of this SQI.
|
static SQI |
readFrom(java.io.InputStream is)
Read this SQI from an XML fragment.
|
void |
setAnnotateUnusedTokensWith(java.lang.String annotateUnusedTokensWith)
The annotation to set on the non-matching part of the input for postprocessing
|
void |
setBreakOnLine(boolean breakOnLine)
If true: maximum one match per line, no match inter-line.
|
void |
setBreakOnParagraph(boolean breakOnParagraph)
If true: maximum one match per paragraph, no match inter-paragraph.
|
void |
setBreakOnSentence(boolean breakOnSentence)
If true: maximum one match per sentence, no match inter-sentence.
(will add SentenceFinder automatically). |
void |
setExplicitAtomMatch(boolean explicitAtomMatch)
If set to true, add extra annotations where named atoms have matched.
|
void |
setMatchAllRules(boolean matchAllRules)
If set to true, return the full list of matched rule.
If false, return only the first matched rule. |
void |
setNoOverlap(boolean noOverlap)
If set to true, don't report overlapping matches, keep the leftmost longest.
|
void |
setPrefix(java.lang.String prefix)
Output annotations prefix
|
void |
setResourceDir(java.lang.String resourceDir)
URL for the resource (data://, file:// or resource://)
|
java.lang.String |
toString()
String representation of this SQI.
|
SQI |
withAnnotateUnusedTokensWith(java.lang.String annotateUnusedTokensWith) |
SQI |
withBreakOnLine(boolean breakOnLine) |
SQI |
withBreakOnLine(java.lang.Boolean breakOnLine) |
SQI |
withBreakOnParagraph(boolean breakOnParagraph) |
SQI |
withBreakOnParagraph(java.lang.Boolean breakOnParagraph) |
SQI |
withBreakOnSentence(boolean breakOnSentence) |
SQI |
withBreakOnSentence(java.lang.Boolean breakOnSentence) |
SQI |
withContexts(java.lang.String contexts) |
SQI |
withExplicitAtomMatch(boolean explicitAtomMatch) |
SQI |
withExplicitAtomMatch(java.lang.Boolean explicitAtomMatch) |
SQI |
withMatchAllRules(boolean matchAllRules) |
SQI |
withMatchAllRules(java.lang.Boolean matchAllRules) |
SQI |
withName(java.lang.String name) |
SQI |
withNoOverlap(boolean noOverlap) |
SQI |
withNoOverlap(java.lang.Boolean noOverlap) |
SQI |
withPrefix(java.lang.String prefix) |
SQI |
withResourceDir(java.lang.String resourceDir) |
SQI |
withSrc(java.lang.String src)
Deprecated.
|
void |
writeTo(java.io.OutputStream os)
Write this SQI as an XML fragment
|
getContexts, getName, getSrc, setContexts, setName, setSrc
public java.lang.String resourceDir
public boolean breakOnSentence
public static final boolean DEFAULT_BREAK_ON_SENTENCE
public boolean breakOnParagraph
public static final boolean DEFAULT_BREAK_ON_PARAGRAPH
public boolean breakOnLine
public static final boolean DEFAULT_BREAK_ON_LINE
public boolean matchAllRules
public static final boolean DEFAULT_MATCH_ALL_RULES
public boolean explicitAtomMatch
public static final boolean DEFAULT_EXPLICIT_ATOM_MATCH
public boolean noOverlap
public static final boolean DEFAULT_NO_OVERLAP
public java.lang.String prefix
public java.lang.String annotateUnusedTokensWith
public SQI()
public SQI(SQI o)
public SQI withName(java.lang.String name)
withName
in class SemanticProcessor
public SQI withContexts(java.lang.String contexts)
withContexts
in class SemanticProcessor
@Deprecated public SQI withSrc(java.lang.String src)
withSrc
in class SemanticProcessor
public void setResourceDir(java.lang.String resourceDir)
public java.lang.String getResourceDir()
public SQI withResourceDir(java.lang.String resourceDir)
public void setBreakOnSentence(boolean breakOnSentence)
public boolean isBreakOnSentence()
public SQI withBreakOnSentence(boolean breakOnSentence)
public SQI withBreakOnSentence(java.lang.Boolean breakOnSentence)
public void setBreakOnParagraph(boolean breakOnParagraph)
public boolean isBreakOnParagraph()
public SQI withBreakOnParagraph(boolean breakOnParagraph)
public SQI withBreakOnParagraph(java.lang.Boolean breakOnParagraph)
public void setBreakOnLine(boolean breakOnLine)
public boolean isBreakOnLine()
public SQI withBreakOnLine(boolean breakOnLine)
public SQI withBreakOnLine(java.lang.Boolean breakOnLine)
public void setMatchAllRules(boolean matchAllRules)
public boolean isMatchAllRules()
public SQI withMatchAllRules(boolean matchAllRules)
public SQI withMatchAllRules(java.lang.Boolean matchAllRules)
public void setExplicitAtomMatch(boolean explicitAtomMatch)
public boolean isExplicitAtomMatch()
public SQI withExplicitAtomMatch(boolean explicitAtomMatch)
public SQI withExplicitAtomMatch(java.lang.Boolean explicitAtomMatch)
public void setNoOverlap(boolean noOverlap)
public boolean isNoOverlap()
public SQI withNoOverlap(boolean noOverlap)
public SQI withNoOverlap(java.lang.Boolean noOverlap)
public void setPrefix(java.lang.String prefix)
public java.lang.String getPrefix()
public SQI withPrefix(java.lang.String prefix)
public void setAnnotateUnusedTokensWith(java.lang.String annotateUnusedTokensWith)
public java.lang.String getAnnotateUnusedTokensWith()
public SQI withAnnotateUnusedTokensWith(java.lang.String annotateUnusedTokensWith)
public SQI makeCopy()
makeCopy
in class SemanticProcessor
public static SQI readFrom(java.io.InputStream is) throws javax.xml.bind.JAXBException
javax.xml.bind.JAXBException
public void writeTo(java.io.OutputStream os) throws javax.xml.bind.JAXBException, java.io.IOException
writeTo
in class SemanticProcessor
javax.xml.bind.JAXBException
java.io.IOException
public static SQI fromString(java.lang.String s) throws javax.xml.bind.JAXBException, java.io.UnsupportedEncodingException
javax.xml.bind.JAXBException
java.io.UnsupportedEncodingException
public java.lang.String toString()
toString
in class SemanticProcessor
public void check(boolean deep, java.lang.String errorContext) throws com.exalead.util.TypedException
check
in interface com.exalead.util.Checkable
check
in class SemanticProcessor
com.exalead.util.TypedException
public void accept(SemanticProcessor.Visitor visitor) throws com.exalead.util.TypedException
accept
in class SemanticProcessor
com.exalead.util.TypedException
public <T> T accept(SemanticProcessor.Transformer<T> transformer, T[] t) throws com.exalead.util.TypedException
accept
in class SemanticProcessor
com.exalead.util.TypedException
Copyright © 2013 Dassault Systèmes, All Rights Reserved.