-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
How to compare two JSON objects? #1007
Comments
The Can you provide an example so I can understand what you mean with "compare indexes"? |
For example, i have this JSON string and parsing it. Let this JSON will be a And this string will be This string I'm parsing into objects. In |
The // start with a copy of the default settings
json s = DefaultSettings;
// overwrite all default settings with those given in Settings
s.update(Settings); Assume |
Big thanks. |
@zkelo FWIW: for a larger use cases you might consider using JSON-schemas for validating JSON objects. |
I have default app settngs in JSON object
DefaultSettings
and I'm parsing current app settings from fileConfig.json
(ifstream). How to compare indexes fromSettings
with indexes inDefaultSettings
? Does library have functions for this? I tried to compare withiterator_wrapper
but he's deprecated.The text was updated successfully, but these errors were encountered: