AXOM
Axom provides a robust, flexible software infrastructure for the development of multi-physics applications and computational tools.
|
Abstract base class defining the interface of all Reader classes. More...
#include </home/docs/checkouts/readthedocs.org/user_builds/axom/checkouts/v0.4.0/src/axom/inlet/Reader.hpp>
Public Member Functions | |
virtual | ~Reader () |
Virtual destructor. More... | |
virtual bool | parseFile (const std::string &filePath)=0 |
Parses the given input file. More... | |
virtual bool | parseString (const std::string &inputString)=0 |
Parses the given string. More... | |
virtual bool | getBool (const std::string &id, bool &value)=0 |
Return a boolean out of the input file. More... | |
virtual bool | getDouble (const std::string &id, double &value)=0 |
Return a double out of the input file. More... | |
virtual bool | getInt (const std::string &id, int &value)=0 |
Return a int out of the input file. More... | |
virtual bool | getString (const std::string &id, std::string &value)=0 |
Return a string out of the input file. More... | |
virtual bool | getIntMap (const std::string &id, std::unordered_map< int, int > &values)=0 |
Get an index-integer mapping for the given array. More... | |
virtual bool | getBoolMap (const std::string &id, std::unordered_map< int, bool > &values)=0 |
Get an index-bool mapping for the given array. More... | |
virtual bool | getDoubleMap (const std::string &id, std::unordered_map< int, double > &values)=0 |
Get an index-double mapping for the given array. More... | |
virtual bool | getStringMap (const std::string &id, std::unordered_map< int, std::string > &values)=0 |
Get an index-string mapping for the given Lua array. More... | |
Abstract base class defining the interface of all Reader classes.
Concrete instances need to inherit from this class and implement these functions.You will need to add your Reader using Reader::initialize
|
inlinevirtual |
Virtual destructor.
References getBool(), getBoolMap(), getDouble(), getDoubleMap(), getInt(), getIntMap(), getString(), getStringMap(), parseFile(), and parseString().
|
pure virtual |
Parses the given input file.
This performs any setup work and parses the given input file. It is required that this is called before using the Reader and overrides any state that was previously there.
[in] | filePath | The Input file to be read |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Parses the given string.
This performs any setup work and parses the given string. It is required that this is called before using the Reader and overrides any state that was previously there.
[in] | inputString | The Input file to be read |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Return a boolean out of the input file.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the bool that will be retrieved |
[out] | value | The value of the bool that was retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Return a double out of the input file.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the double that will be retrieved |
[out] | value | The value of the double that was retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Return a int out of the input file.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the int that will be retrieved |
[out] | value | The value of the int that was retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Return a string out of the input file.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the string that will be retrieved |
[out] | value | The value of the string that was retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Get an index-integer mapping for the given array.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the string that will be retrieved |
[out] | map | The values of the ints that were retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Get an index-bool mapping for the given array.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the string that will be retrieved |
[out] | map | The values of the bools that were retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Get an index-double mapping for the given array.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the string that will be retrieved |
[out] | map | The values of the doubles that were retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().
|
pure virtual |
Get an index-string mapping for the given Lua array.
This performs any necessary retrieval and mapping from the given identifier to what is in the input file.
[in] | id | The identifier to the string that will be retrieved |
[out] | map | The values of the strings that were retrieved |
Implemented in axom::inlet::LuaReader.
Referenced by ~Reader().