Public Member Functions | List of all members
nom::JSON::FileReader Class Reference

Wrapper class for JSON input with JSONCPP. More...

#include <FileReader.hpp>

Public Member Functions

bool load (const std::string &filename, Value &object, bool parse_comments=false)
 
void dump_key (const ValueType &object) const
 Debugging aid; helper method for nom::JSON::FileReader::dump.
 
void dump_value (const ValueType &key) const
 Debugging aid; helper method for nom::JSON::FileReader::dump.
 
bool dump (const ValueType &object, int depth=0) const
 

Detailed Description

Wrapper class for JSON input with JSONCPP.

[TO BE WRITTEN]

The dump methods originate (with my modifications) from:

http://stackoverflow.com/questions/4800605/jsoncpp-iterate-thru-all-the-objects

Definition at line 46 of file FileReader.hpp.

Member Function Documentation

bool nom::JSON::FileReader::dump ( const ValueType &  object,
int  depth = 0 
) const

A convenient, detailed console output dump of the JSON object, as the underlying engine (JSONCPP) sees it.

Definition at line 151 of file FileReader.cpp.

Here is the call graph for this function:

bool nom::JSON::FileReader::load ( const std::string &  filename,
Value &  object,
bool  parse_comments = false 
)

Load JSON input from a specified file path

Parameters
filenameAbsolute file path
objectnom::JSON::Value object container for storing parsed JSON file input
parse_commentsDisabled by default

Definition at line 37 of file FileReader.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following files: