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

JSON into vector #335

Closed
Lerian715 opened this issue Oct 15, 2016 · 4 comments
Closed

JSON into vector #335

Lerian715 opened this issue Oct 15, 2016 · 4 comments

Comments

@Lerian715
Copy link

Hi!
Is it possible to convert directly stream into vector? For eg.
load file with JSON >> create vector on this data

@nlohmann
Copy link
Owner

You may have a look at #332 (comment). If this does not help, please provide a concrete example.

@ibitton
Copy link

ibitton commented Oct 20, 2016

I think you should try:
auto vec = myJSON.get<vector<T>>();

@nlohmann nlohmann added the state: please discuss please discuss the issue or vote for your favorite option label Oct 22, 2016
@nlohmann
Copy link
Owner

@ibitton Can we close this issue?

@vertisan
Copy link

Yes

@nlohmann nlohmann removed the state: please discuss please discuss the issue or vote for your favorite option label Oct 23, 2016
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

4 participants