build.gradle - Run xslt transformation in gradle with parameter - Stack Overflow

admin2025-04-18  4

I want to run my xslt transformation in gradle with parameter. How can I set the parameter? I have the following code in build.gradle:

`SaxonXslt transform = new SaxonXslt()
transform.options = [
        stylesheet: Paths.get(xsltPath).toFile()
        input     : inputFile.toFile(),
        output    : outputfile.toFile(),
]
transform.parameters('param1', valueOfParam1)
transform.run()`

it starts xslt but with empty parameter

转载请注明原文地址:http://www.anycun.com/QandA/1744925820a89576.html