The XML transform actions let you transform XML with XSTL. Table 11.25 lists the XML transform actions. Table 11.25. XML Transform Actions
Syntax: [34]
Syntax #1: Without a body <x:transform xml xslt [xmlSystemId] [xsltSystemId] [{var [scope] result}]/> Syntax #2: With a body that specifies transformation parameters in the body <x:transform xml xslt [xmlSystemId] [xsltSystemId] [{var [scope] result}]> <x:param> actions </x:transform> Syntax #3: With a body that specifies an XML document and optional transformation parameters in the body <x:transform xslt [xmlSystemId] [xsltSystemId] [{var [scope] result}]> xml optional <x:param> actions </x:transform> Description: The <x:transform> action transforms an XML document, using an XSLT stylesheet. Attributes:
Constraints and Error Handling:
In a Nutshell : By default, <x:transform> sends the transformed XML document to the current JspWriter . You can specify the name of a scoped variable that references an org.w3c.dom.Document object representing the transformed document with the var attribute. You can also specify a scope for that variable with the scope attribute. You can also save the transformed XML document in an object whose type is javax.xml.transform.Result by specifying the object's name with the result attribute. Additionally, you can specify URIs for the xmlSystemId and xsltSystemId attributes, which are used to locate external entities for the XML document and XSLT stylesheet, respectively.
Syntax: Syntax #1: Without a body, with a value specified by the value attribute <x:param name value/> Syntax #2: With a body, specifying a value in the body of the action <x:param name> value </x:param> Description: The <x:param> action specifies a parameter for an XSLT transformation. Attributes:
In a Nutshell: All action:nutshell summary]><x:param> actions must reside in the body of an <x:transform> action; the former sets a transformation parameter for the latter. You must specify the name of the parameter with the name attribute. You can specify the value of the parameter with the value attribute or in the body of the <x:param> action. |