FMT 0.9.8
Forest management tools for forest planning
Loading...
Searching...
No Matches
FMTwarning.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 FMTwarning_H_INCLUDED
9#define FMTwarning_H_INCLUDED
10
11#include <unordered_map>
12#include "FMTexception.hpp"
13#include <string>
14#include <memory>
15#include "FMTutility.hpp"
16#include <boost/serialization/nvp.hpp>
17
18namespace Logging
19{
20 class FMTlogger;
21}
22
23namespace Exception
24{
25 // DocString: FMTwarning
32 {
33 // DocString: FMTwarning::serialize
37 friend class boost::serialization::access;
38 template<class Archive>
39 void serialize(Archive& ar, const unsigned int version)
40 {
41 ar & boost::serialization::make_nvp("parent_exception", boost::serialization::base_object<FMTexception>(*this));
42 }
43 public:
44 // DocString: ~FMTwarning()
48 ~FMTwarning()=default;
49 // DocString: FMTwarning::operator=
53 FMTwarning& operator = (const FMTwarning&) = default;
54 // DocString: FMTwarning()
59 // DocString: FMTwarning(const FMTexception&)
64 // DocString: FMTwarning(const FMTexc,const std::string)
68 FMTwarning(const FMTexc lexception, const std::string message);
69 // DocString: FMTwarning(const FMTexc,const Core::FMTsection,const std::string)
73 FMTwarning(const FMTexc lexception, const Core::FMTsection lsection, const std::string message);
74 // DocString: FMTwarning(const FMTexc,const Core::FMTsection, const std::string,const std::string&,const std::string&,const std::string&)
79 FMTwarning(const FMTexc lexception, const Core::FMTsection lsection, const std::string message,
80 const std::string& lmethod, const std::string& lfile, const int& lline);
81 // DocString: FMTwarning::warn
85 void warn(const std::shared_ptr<Logging::FMTlogger>logger,std::unordered_map<int,size_t>& specificwarningcount, const size_t& maxwarning) const;
86 };
87}
88#endif
#define FMTEXPORT
Definition: FMTutility.hpp:92
Definition: FMTexception.hpp:134
Definition: FMTwarning.hpp:32
FMTwarning(const FMTexc lexception, const Core::FMTsection lsection, const std::string message, const std::string &lmethod, const std::string &lfile, const int &lline)
FMTwarning(const FMTexc lexception, const std::string message)
FMTwarning(const FMTexc lexception, const Core::FMTsection lsection, const std::string message)
FMTwarning(const FMTexception &rhs)
void warn(const std::shared_ptr< Logging::FMTlogger >logger, std::unordered_map< int, size_t > &specificwarningcount, const size_t &maxwarning) const
FMTsection
Definition: FMTutility.hpp:23
Namespace for exceptions and exceptions handling (warnings and errors) thrown by FMT and all exceptio...
Definition: FMTcplhandler.hpp:16
FMTexc
Definition: FMTexception.hpp:42
Namespace for the log management, provides different log handlers.
Definition: FMTdebuglogger.hpp:14