We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
For very simple XSL transformations, it might be useful to implement a simple DSL that allows for constructing XSL templates on the fly:
stylesheet( template( match("book"), element("book", attribute("id", "{@id + 1}"), applyTemplates() ) ), template( match("@*|*|processing-instruction()|comment()"), copy( applyTemplates(select("*|@*|text()|processing-instruction()|comment()")) ) ) );
The above would roughly be equivalent to:
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="book"> <book id="{@id + 1}"> <xsl:apply-templates/> </book> </xsl:template> <xsl:template match="@*|*|processing-instruction()|comment()"> <xsl:copy> <xsl:apply-templates select="*|@*|text()|processing-instruction()|comment()"/> </xsl:copy> </xsl:template> </xsl:stylesheet>
Possibly, the DSL could be generated from the XSL XSD
The text was updated successfully, but these errors were encountered:
No branches or pull requests
For very simple XSL transformations, it might be useful to implement a simple DSL that allows for constructing XSL templates on the fly:
The above would roughly be equivalent to:
Possibly, the DSL could be generated from the XSL XSD
The text was updated successfully, but these errors were encountered: