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

add xml node property row and column in document file #178

Closed
xfcanyue opened this issue Jan 17, 2018 · 2 comments
Closed

add xml node property row and column in document file #178

xfcanyue opened this issue Jan 17, 2018 · 2 comments

Comments

@xfcanyue
Copy link

sometimes, i need to know a xml_node's location in the document.

it's useful to edit xml from another program interface. when edited, dynamically update the document, not reload the document.

thanks very much, i like pugixml.

@zeux
Copy link
Owner

zeux commented Jan 17, 2018

Currently the parser doesn't track row/column information, and there's also no space in the node to store this (making nodes larger would penalize workloads that don't need this info).

You do have xml_node::offset_debug(); it is essentially a byte position of the node in the file, which could be used to recover the row/column offset manually (of course that's a bit cumbersome).

I do have a plan to introduce a separate, optional table that could be used to store & query this data; this is tracked in #12.

@zeux zeux closed this as completed Jan 17, 2018
@zeux zeux added the duplicate label Jan 17, 2018
@xfcanyue
Copy link
Author

did you have finished this plan ?

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

No branches or pull requests

2 participants