pelib
2.0.0
|
#include <AmplInputScalar.hpp>
Public Member Functions | |
AmplInputScalar (bool strict=true) | |
virtual AmplInputScalar * | clone () const |
virtual AlgebraData * | parse (std::istream &in) |
virtual void | dump (std::ostream &stream, const AlgebraData *data) const |
virtual std::string | getDetailedPattern () |
virtual std::string | getGlobalPattern () |
Protected Attributes | |
bool | strict |
Base class for a parser or output class of a scalar in AMPL input data format
Definition at line 36 of file AmplInputScalar.hpp.
pelib::AmplInputScalar< Value >::AmplInputScalar | ( | bool | strict = true | ) | [inline] |
Constructor
strict | If true and parsing floating point values, fails when reading any integer value if not written with a trailing decimal 0, e.g. 52.0 |
Definition at line 43 of file AmplInputScalar.hpp.
virtual AmplInputScalar* pelib::AmplInputScalar< Value >::clone | ( | ) | const [inline, virtual] |
Return a pointer to a copy of this class instance
Implements pelib::AmplInputDataOutput.
Definition at line 51 of file AmplInputScalar.hpp.
virtual void pelib::AmplInputScalar< Value >::dump | ( | std::ostream & | stream, |
const AlgebraData * | data | ||
) | const [inline, virtual] |
Writes an instance of class that derives from pelib::AlgebraData to output stream
stream | Output stream that receives the written output of AlgebraData |
data | Instance of a class derived from AlgebraData to write to output stream |
Implements pelib::AlgebraDataOutput.
Definition at line 93 of file AmplInputScalar.hpp.
virtual std::string pelib::AmplInputScalar< Value >::getDetailedPattern | ( | ) | [inline, virtual] |
Matches a data structure written in AMPL input data format and extract its name and content
Implements pelib::AlgebraDataParser.
Definition at line 110 of file AmplInputScalar.hpp.
virtual std::string pelib::AmplInputScalar< Value >::getGlobalPattern | ( | ) | [inline, virtual] |
Matches a data structure written in AMPL input data format
Implements pelib::AlgebraDataParser.
Definition at line 118 of file AmplInputScalar.hpp.
virtual AlgebraData* pelib::AmplInputScalar< Value >::parse | ( | std::istream & | in | ) | [inline, virtual] |
Parse input stream in AMPL input format and builds an instance of a derivative class of pelib::AlgebraData containing the values read
Implements pelib::AlgebraDataParser.
Definition at line 59 of file AmplInputScalar.hpp.
bool pelib::AmplInputScalar< Value >::strict [protected] |
Defines if parsing should be performed in strict mode
Definition at line 125 of file AmplInputScalar.hpp.