FMT 0.9.8
Forest management tools for forest planning
Loading...
Searching...
No Matches
FMTfork.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 FMTFORK_H_INCLUDED
9#define FMTFORK_H_INCLUDED
10
11#include "FMTtransitionmask.hpp"
12#include "FMTbounds.hpp"
13#include <vector>
14#include <boost/serialization/serialization.hpp>
15#include <boost/serialization/split_member.hpp>
16#include <boost/serialization/nvp.hpp>
17#include <boost/serialization/export.hpp>
18#include <boost/serialization/unique_ptr.hpp>
19#include <boost/serialization/vector.hpp>
20#include "FMTobject.hpp"
21
22namespace Core
23{
24
25class FMTdevelopment;
26class FMTdevelopmentpath;
27class FMTyieldrequest;
28class FMTyields;
29class FMTtheme;
30class FMTmaskfilter;
31
32
33class FMTEXPORT FMTfork : public FMTspec, public FMTobject
34 {
35 friend class boost::serialization::access;
36 template<class Archive>
37 void serialize(Archive& ar, const unsigned int version)
38 {
39 ar& boost::serialization::make_nvp("specifications", boost::serialization::base_object<FMTspec>(*this));
40 ar& transitions;
41 }
42 std::vector<FMTtransitionmask>transitions;
43 public:
45 FMTfork(const FMTfork& rhs);
47 FMTfork& operator = (const FMTfork& rhs);
48 void add(const FMTtransitionmask& transition);
49 void clear();
50 std::vector<FMTdevelopmentpath> getpaths(const Core::FMTdevelopment& base, const Core::FMTyields& ylds,
51 const std::vector<FMTtheme>& themes,const bool& reset_age) const;
52 FMTdevelopment getmax(const FMTdevelopment& base,const FMTyields& ylds,const std::vector<FMTtheme>& themes, const bool& reset_age) const;
53 std::vector<FMTtransitionmask> getmasktrans() const;
54 bool operator == (const FMTfork& rhs) const;
55 FMTfork single() const;
56 double sumprop() const;
57 size_t size() const;
58 FMTfork presolve(const FMTmaskfilter& filter, const std::vector<FMTtheme>&presolvedthemes) const;
59 operator std::string() const override;
60 };
61
62}
63
64BOOST_CLASS_EXPORT_KEY(Core::FMTfork)
65
66#endif // FMTFORK_H_INCLUDED
#define FMTEXPORT
Definition: FMTutility.hpp:92
Definition: FMTdevelopment.hpp:44
Definition: FMTfork.hpp:34
double sumprop() const
FMTfork presolve(const FMTmaskfilter &filter, const std::vector< FMTtheme > &presolvedthemes) const
void add(const FMTtransitionmask &transition)
std::vector< FMTtransitionmask > getmasktrans() const
std::vector< FMTdevelopmentpath > getpaths(const Core::FMTdevelopment &base, const Core::FMTyields &ylds, const std::vector< FMTtheme > &themes, const bool &reset_age) const
size_t size() const
FMTfork single() const
FMTfork(const FMTfork &rhs)
FMTdevelopment getmax(const FMTdevelopment &base, const FMTyields &ylds, const std::vector< FMTtheme > &themes, const bool &reset_age) const
Definition: FMTmaskfilter.hpp:27
Definition: FMTobject.hpp:50
Definition: FMTbounds.hpp:342
Definition: FMTtransitionmask.hpp:29
Definition: FMTyields.hpp:40
The Core namespace provides classes for simulating stands/strata growth/harvest through time.
Definition: FMTaction.hpp:31