public class PatternOptimizationEE extends PatternOptimization
Modifier and Type | Field and Description |
---|---|
List<IndexDefn> |
indexDefnList |
int |
indexMinUses |
String |
name |
List<PreconditionDefn> |
preconditionDefnList |
int |
preconditionMinUses |
List<RewriteDefn> |
rewriteDefnList |
Constructor and Description |
---|
PatternOptimizationEE() |
Modifier and Type | Method and Description |
---|---|
boolean |
checkBoolean(String value) |
void |
export(ExpressionPresenter out)
Export any information pertinent to pattern optimization, not attached to specific rules
|
boolean |
isDITA()
Ask whether DITA-OT indexing is to be used
|
boolean |
isDITA2() |
boolean |
isIndexComparisonPredicates()
Ask whether rule indexing based on predicate comparisons is to be used
|
boolean |
isOptimize()
Ask whether optimization is enabled
By default it is true if a pattern optimization element exists.
|
boolean |
isPreconditions()
Ask whether template rule preconditions should be computed
|
boolean |
isUseIndexRules()
Ask whether rule indexing is to be used
|
boolean |
isUseRewrites()
Ask whether rewrites should be used
|
boolean |
isUseRuleOptimization()
Ask whether template rules should be optimized
|
boolean |
isUseTokenization()
Ask whether parts of patterns in template rules can employ tokenization
|
boolean |
isUseWhichOfExpressions()
Ask whether template rules are be converted to whichOf expressions
|
static void |
readPatternIndex(Configuration config,
Attributes atts) |
static void |
readPatternIndex(Configuration config,
Map<String,String> props)
Read a rule indexation structure from a map, rather than a set of attributes
TODO - remove when dita2 option is removed.
|
static void |
readPatternOptimization(Configuration config,
Attributes atts)
Initialize the PatternOptimization object in the default XSLT compilation options from attributes in a configuration file
|
static void |
readPatternPrecondition(Configuration config,
Attributes atts) |
static void |
readPatternRewrite(Configuration config,
Attributes atts) |
void |
setConfigurationProperty(String name,
String value)
Set an optimization option on or off
|
void |
setIndexRules() |
void |
setOptimize() |
void |
setPreconditions() |
void |
setRewrites() |
void |
write(XMLStreamWriter out)
Write information about the pattern optimizer (may be used in statistics)
|
public String name
public int preconditionMinUses
public int indexMinUses
public List<PreconditionDefn> preconditionDefnList
public List<RewriteDefn> rewriteDefnList
public boolean isOptimize()
isOptimize
in class PatternOptimization
public void setOptimize()
public boolean isUseRuleOptimization()
public boolean isPreconditions()
public void setPreconditions()
public boolean isUseWhichOfExpressions()
public boolean isUseTokenization()
public boolean isUseRewrites()
public void setRewrites()
public boolean isUseIndexRules()
public void setIndexRules()
public boolean isIndexComparisonPredicates()
public boolean isDITA()
public boolean isDITA2()
public static void readPatternOptimization(Configuration config, Attributes atts) throws XPathException
config
- the Saxon configurationatts
- the attributes of an element in a configuration fileXPathException
- if the supplied attributes contain invalid optionspublic static void readPatternPrecondition(Configuration config, Attributes atts) throws XPathException
XPathException
public static void readPatternRewrite(Configuration config, Attributes atts) throws XPathException
XPathException
public static void readPatternIndex(Configuration config, Attributes atts) throws XPathException
XPathException
public static void readPatternIndex(Configuration config, Map<String,String> props) throws XPathException
config
- the configurationprops
- the properties of the rule indexationXPathException
- if there is an error in initialisationpublic void setConfigurationProperty(String name, String value) throws IllegalArgumentException
name
- the name of the option to be setvalue
- the value (yes or no)IllegalArgumentException
- if the value is invalidpublic boolean checkBoolean(String value) throws IllegalArgumentException
IllegalArgumentException
public void export(ExpressionPresenter out)
out
- the destination for the informationpublic void write(XMLStreamWriter out)
write
in class PatternOptimization
out
- the stream to write toCopyright (c) 2004-2014 Saxonica Limited. All rights reserved.