|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.dom4j.rule.Stylesheet
Stylesheet
implements an XSLT stylesheet such that rules can
be added to the stylesheet and the stylesheet can be applied to a source
document or node.
Constructor Summary | |
Stylesheet()
Creates a new empty stylesheet. |
Method Summary | |
void |
addRule(Rule rule)
Add a rule to this stylesheet. |
void |
applyTemplates(Object input)
If input is a Node , this will processes all of the
children of that node. |
void |
applyTemplates(Object input,
String mode)
Processes the input object in the given mode. |
void |
applyTemplates(Object input,
XPath xpath)
Processes the result of the xpath expression. |
void |
applyTemplates(Object input,
org.jaxen.XPath xpath)
Deprecated. Use applyTemplates(Object, XPath) instead. |
void |
applyTemplates(Object input,
XPath xpath,
String mode)
Processes the result of the xpath expression in the given mode. |
void |
applyTemplates(Object input,
org.jaxen.XPath xpath,
String mode)
Deprecated. Use applyTemplates(Object, XPath, String)
instead. |
void |
clear()
|
String |
getModeName()
DOCUMENT ME! |
Action |
getValueOfAction()
DOCUMENT ME! |
void |
removeRule(Rule rule)
Removes the specified rule from this stylesheet. |
void |
run(List list)
|
void |
run(List list,
String mode)
|
void |
run(Node node)
|
void |
run(Node node,
String mode)
|
void |
run(Object input)
Runs this stylesheet on the given input which should be either a Node or a List of Node objects. |
void |
run(Object input,
String mode)
|
void |
setModeName(String modeName)
Sets the name of the mode that the stylesheet uses by default. |
void |
setValueOfAction(Action valueOfAction)
Sets the default value-of action which is used in the default rules for the pattern "text()|@" |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Stylesheet()
Method Detail |
public void addRule(Rule rule)
rule
- the rule to addpublic void removeRule(Rule rule)
rule
- the rule to removepublic void run(Object input) throws Exception
input
- the input to run this stylesheet on
Exception
- if something goes wrongpublic void run(Object input, String mode) throws Exception
Exception
public void run(List list) throws Exception
Exception
public void run(List list, String mode) throws Exception
Exception
public void run(Node node) throws Exception
Exception
public void run(Node node, String mode) throws Exception
Exception
public void applyTemplates(Object input, XPath xpath) throws Exception
input
- the input objectxpath
- the xpath expression
Exception
- if something goes wrongpublic void applyTemplates(Object input, XPath xpath, String mode) throws Exception
input
- the input objectxpath
- the xpath expressionmode
- the mode
Exception
- if something goes wrongpublic void applyTemplates(Object input, org.jaxen.XPath xpath) throws Exception
applyTemplates(Object, XPath)
instead.
input
- the input objectxpath
- the xpath expression
Exception
- if something goes wrongpublic void applyTemplates(Object input, org.jaxen.XPath xpath, String mode) throws Exception
applyTemplates(Object, XPath, String)
instead.
input
- the input objectxpath
- the xpath expressionmode
- the mode
Exception
- if something goes wrongpublic void applyTemplates(Object input) throws Exception
Node
, this will processes all of the
children of that node. If input is a List
of
Nodes
s, these nodes will be iterated and all children of
each node will be processed.
input
- the input object, this can either be a Node
or
a List
Exception
- if something goes wrongpublic void applyTemplates(Object input, String mode) throws Exception
Node
, this will processes all of the children of that
node. If input is a List
of Nodes
s, these
nodes will be iterated and all children of each node will be processed.
input
- the input object, this can either be a Node
or
a List
mode
- the mode
Exception
- if something goes wrongpublic void clear()
public String getModeName()
public void setModeName(String modeName)
modeName
- DOCUMENT ME!public Action getValueOfAction()
public void setValueOfAction(Action valueOfAction)
valueOfAction
- DOCUMENT ME!
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |