-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
While XML.jl does a great job just with parsing/writing XML documents, it would be great if it provided a few facilities to help work with them too.
One that would be really nice to see is XPath support. I've implemented a simple subset of XPath as a macro in a package of mine:
https://code.tecosaur.net/tec/RestClient.jl/src/branch/main/ext/XMLExt.jl#L102
It works by producing an XPath-getting function from the macro, e.g.
julia> @macroexpand @xpath "some/xpath/@attr"
node -> extract_attr(extract_child(extract_child(node, "some"), "xpath"), "attr")
Perhaps that could be a useful starting point or at least of interest?
Metadata
Metadata
Assignees
Labels
No labels