Updated How To Parse A Document (Old API) (markdown)

This commit is contained in:
Jesse Beder 2015-03-29 22:55:32 -05:00 committed by Martin Delille
parent c775aec2e3
commit 7fe341ab4a
No known key found for this signature in database
GPG Key ID: 9E8539581F123D43

View File

@ -87,7 +87,7 @@ One thing to be keep in mind: reading a map by key (as immediately above) requir
## Optional Keys ##
If you try to access a key that doesn't exist, `yaml-cpp` throws an exception (see [When Something Goes Wrong](https://github.com/jbeder/yaml-cpp/wiki/HowToParseADocument(OldApi)#When_Something_Goes_Wrong) When Something Goes Wrong). If you have optional keys, you it's often easier to use `FindValue` instead of `operator[]`:
If you try to access a key that doesn't exist, `yaml-cpp` throws an exception (see [When Something Goes Wrong](https://github.com/jbeder/yaml-cpp/wiki/How-To-Parse-A-Document-(Old-API)#When_Something_Goes_Wrong). If you have optional keys, you it's often easier to use `FindValue` instead of `operator[]`:
```
YAML::Node doc; // already parsed