FMT 0.9.8
Forest management tools for forest planning
Loading...
Searching...
No Matches
FMToutputparser.hpp
Go to the documentation of this file.
1/*
2Copyright (c) 2019 Gouvernement du Québec
3
4SPDX-License-Identifier: LiLiQ-R-1.1
5License-Filename: LICENSES/EN/LiLiQ-R11unicode.txt
6*/
7
8#ifndef FMToutputparser_H_INCLUDED
9#define FMToutputparser_H_INCLUDED
10
11#include "FMTparser.hpp"
12#include "FMTutility.hpp"
13#include <boost/regex.hpp>
14#include <string>
15
16namespace Core
17{
18 class FMTtheme;
19 class FMTaction;
20 class FMTyields;
21 class FMTconstants;
22 class FMToutput;
23 class FMToutputsource;
24 class FMToperator;
25}
26
27namespace Parser
28
29{
30// DocString: FMToutputparser
35 {
36 // DocString: FMToutputparser::rxoutput
38 const static boost::regex rxoutput;
39 // DocString: FMToutputparser::rxsource
41 const static boost::regex rxsource;
42 // DocString: FMToutputparser::rxtar
44 const static boost::regex rxtar;
45 // DocString: FMToutputparser::rxgrp
47 const static boost::regex rxgrp;
48 // DocString: FMToutputparser::rxoutputconstant
50 const static boost::regex rxoutputconstant;
51 // DocString: FMToutputparser::readnfill
55 void readnfill(std::vector<Core::FMToutput>* outputs,
56 const std::vector<Core::FMTtheme>& themes,
57 const std::vector<Core::FMTaction>& actions,
58 const Core::FMTyields& ylds,const Core::FMTconstants& constants,
59 const std::string& location);
60 // DocString: FMToutputparser::appendtooutput
64 void appendtooutput(
65 const std::string& strvalue,
66 const int& outputid,
67 const int& themetarget,
68 const size_t& lastoutput,
69 std::string& lastoperator,
70 std::vector<std::string>& stroperators,
71 std::vector<Core::FMToutputsource>& sources,
72 std::vector<Core::FMToperator>& operators) const;
73
74 public:
75 // DocString: FMToutputparser()
80 // DocString: ~FMToutputparser()
84 ~FMToutputparser() = default;
85 // DocString: FMToutputparser(const FMToutputparser&)
89 FMToutputparser(const FMToutputparser& rhs)=default;
90 // DocString: FMToutputparser::operator=
94 FMToutputparser& operator = (const FMToutputparser& rhs)=default;
95 // DocString: FMToutputparser::read
99 std::vector<Core::FMToutput> read(const std::vector<Core::FMTtheme>& themes,
100 const std::vector<Core::FMTaction>& actions,
101 const Core::FMTyields& ylds,const Core::FMTconstants& constants,
102 const std::string& location);
103 // DocString: FMToutputparser::addoutputs
109 std::vector<Core::FMToutput> addoutputs(const std::vector<Core::FMToutput> oldoutputs,
110 const std::vector<Core::FMTtheme>& themes,
111 const std::vector<Core::FMTaction>& actions,
112 const Core::FMTyields& ylds,const Core::FMTconstants& constants,
113 const std::string& location,
114 std::vector<std::string> outputsnames = std::vector<std::string>());
115 // DocString: FMToutputparser::write
119 void write(const std::vector<Core::FMToutput>& outputs,const std::string& location) const;
120 };
121
122}
123
124
125#endif // FMToutputparser_H_INCLUDED
#define FMTEXPORT
Definition: FMTutility.hpp:92
Definition: FMTconstants.hpp:29
Definition: FMTyields.hpp:40
Definition: FMToutputparser.hpp:35
std::vector< Core::FMToutput > addoutputs(const std::vector< Core::FMToutput > oldoutputs, const std::vector< Core::FMTtheme > &themes, const std::vector< Core::FMTaction > &actions, const Core::FMTyields &ylds, const Core::FMTconstants &constants, const std::string &location, std::vector< std::string > outputsnames=std::vector< std::string >())
FMToutputparser(const FMToutputparser &rhs)=default
std::vector< Core::FMToutput > read(const std::vector< Core::FMTtheme > &themes, const std::vector< Core::FMTaction > &actions, const Core::FMTyields &ylds, const Core::FMTconstants &constants, const std::string &location)
void write(const std::vector< Core::FMToutput > &outputs, const std::string &location) const
Definition: FMTparser.hpp:66
The Core namespace provides classes for simulating stands/strata growth/harvest through time.
Definition: FMTaction.hpp:31
Namespace handling all FMT's parsers. Everything related to I/O should be located in this namespace.
Definition: FMTactionparser.hpp:26