Skip to content
New issue

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

get-xml-file-static-dependency-tree: dealing with fn:transform #21

Open
mricaud opened this issue Sep 28, 2020 · 2 comments
Open

get-xml-file-static-dependency-tree: dealing with fn:transform #21

mricaud opened this issue Sep 28, 2020 · 2 comments

Comments

@mricaud
Copy link
Owner

mricaud commented Sep 28, 2020

As Liam Quin said in https://xmlcom.slack.com/archives/C011NLXE4DU/p1601234961085300?thread_ts=1601201199.078900&cid=C011NLXE4DU, it would be a nice idea to deal with fn:transform ()

fn:transform takes a map as input. This map defines stylesheet-location which might be parsed to get a new dependency.
If the language is XSLT (it could be schematron or xspec or any other languages using xpath) then we have to be carefull that the value is not dynamically computed.

@cmarchand
Copy link
Contributor

Not an easy thing to do ! The map can be written inline in the XPath expression, but it can also be constructed via function calls, parameters, etc... So you have to evaluate the XPath expression, but also the whole XSL, and even its imported/included/used-package dependencies !
But you are able to do this !
Have a look at this : https://bottlecaps.de/rex/ It generates a parser in XSLT for the language you need. XPath and XSLT are supported.

@mricaud
Copy link
Owner Author

mricaud commented Sep 29, 2020

This has to do with issues #4, but I think it has no sens because the xpath could be related to the XML input file which is not a static dependency :)
But as Liam suggested : just writing the xpath as dependency (not going further) would be an helpfull information, fair enough :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants