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 root node? #86

Open
egordorichev opened this issue May 4, 2016 · 3 comments
Open

Get root node? #86

egordorichev opened this issue May 4, 2016 · 3 comments

Comments

@egordorichev
Copy link

Hello!

If there is a way to get the root array in this code?

{
  book = {
    author = "Me",
    title = "JSON"
  }
}

Thanks!

@kazuho
Copy link
Owner

kazuho commented May 4, 2016

I am not sure of your example, but generally speaking, picojson::value does not retain a pointer to the parent node.

@egordorichev
Copy link
Author

Can you add this to your feature project, please?

@kazuho
Copy link
Owner

kazuho commented May 5, 2016

I am sorry but no, since there is nothing like a document object in picojson. We only have values.

You should try to retain the root object within your code, if that's required.

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