8#ifndef FMTyieldparser_Hm_included
9#define FMTyieldparser_Hm_included
14#include <boost/regex.h>
27 class FMTYieldHandler;
83 const static boost::regex m_rxyieldtype;
86 const static boost::regex m_rxcomplex;
89 const static boost::regex m_rxeqs;
92 const static boost::regex m_rxdiscount;
95 const static boost::regex m_rxpredictor;
97 const static boost::regex m_rxyieldsolo;
129 std::vector<std::pair<
Core::FMTMask,std::unique_ptr<Core::FMTYieldHandler>>>::iterator actualyield,
130 const std::vector<std::string>& values)
const;
139 std::vector<std::pair<
Core::FMTMask, std::unique_ptr<Core::FMTYieldHandler>>>::iterator actualyield,
140 const std::string& yld)
const;
146 void _checkPreExisting(
const std::vector<std::string>& preexists)
const;
153 bool _isFunction(
const std::string& strfunction)
const;
163 double _getNumwithproportion(
const std::string& value,
const Core::FMTConstants& constants,
164 const std::vector<double>& proportions,
const int& location);
177 const std::vector<Core::FMTTheme>& themes);
195 std::map<std::string, double> _getIndexValues(
const Core::FMTMask& mask,
196 const std::vector<Core::FMTTheme>& themes,
197 const std::vector<std::string>&indexvalues,
const Core::FMTConstants& constants)
const;
206 std::unique_ptr<Core::FMTYieldModel> _readYieldModel(
const std::string& modelname, std::vector<std::string>& modelYields,
const Core::FMTMask& mainmask)
const;
#define FMTEXPORT
Definition: FMTutility.h:125
Class holding the constants defined in the constants section of a model, used by the parsers.
Definition: FMTConstants.h:28
Data of a yield holding the values, sources and operators used to compute complex yields.
Definition: FMTData.h:36
Core class holding, as a boost dynamic bitset, which theme attributes are part of a mask.
Definition: FMTMask.h:96
FMTList containing multiple yield handlers as seen in the yield section, holding the information rela...
Definition: FMTYields.h:44
Main parent class of all the parsers in FMT.
Definition: FMTParser.h:72
Parser reading and writing yield sections into a FMTYields object.
Definition: FMTYieldParser.h:39
Core::FMTYields read(const std::vector< Core::FMTTheme > &themes, const Core::FMTConstants &constants, const std::string &location)
Read a yield file into a FMTYields object.
FMTYieldParser()
Default constructor for FMTYieldParser.
FMTYieldParser(const FMTYieldParser &rhs)=default
Copy constructor for FMTYieldParser.
~FMTYieldParser()=default
Default destructor for FMTYieldParser.
void write(const Core::FMTYields &yields, const std::string &location) const
Write a FMTYields object to a file.
The Core namespace provides classes for simulating stands/strata growth/harvest through time.
Definition: FMTAction.h:34
FMTyldtype
Enumerator describing the type of a yield (age, time, complex, model).
Definition: FMTutility.h:62
FMTyieldparserop
Enumerator describing the operators usable in the yield section.
Definition: FMTutility.h:74
Namespace handling all FMT's parsers. Everything related to I/O should be located in this namespace.
Definition: FMTActionParser.h:27