Antares Simulator
Power System Simulator
Loading...
Searching...
No Matches
ISimulationObserver.h
1
2/*
3 * Copyright 2007-2024, RTE (https://www.rte-france.com)
4 * See AUTHORS.txt
5 * SPDX-License-Identifier: MPL-2.0
6 * This file is part of Antares-Simulator,
7 * Adequacy and Performance assessment for interconnected energy networks.
8 *
9 * Antares_Simulator is free software: you can redistribute it and/or modify
10 * it under the terms of the Mozilla Public Licence 2.0 as published by
11 * the Mozilla Foundation, either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * Antares_Simulator is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * Mozilla Public Licence 2.0 for more details.
18 *
19 * You should have received a copy of the Mozilla Public Licence 2.0
20 * along with Antares_Simulator. If not, see <https://opensource.org/license/mpl-2-0/>.
21 */
22
23#pragma once
24
25#include "sim_structure_probleme_economique.h"
26
27namespace Antares::Solver::Simulation
28{
29
36{
37public:
38 virtual ~ISimulationObserver() = default;
45 virtual void notifyHebdoProblem(const PROBLEME_HEBDO& problemeHebdo,
46 int optimizationNumber,
47 std::string_view name)
48 = 0;
49};
50
57{
58public:
59 ~NullSimulationObserver() override = default;
60
61 void notifyHebdoProblem(const PROBLEME_HEBDO&, int, std::string_view) override
62 {
63 // null object pattern
64 }
65};
66} // namespace Antares::Solver::Simulation
The ISimulationObserver class is an interface for observing the simulation.
Definition ISimulationObserver.h:36
virtual void notifyHebdoProblem(const PROBLEME_HEBDO &problemeHebdo, int optimizationNumber, std::string_view name)=0
The notifyHebdoProblem method is used to notify of a problem during the simulation.
The NullSimulationObserver class is a null object for the ISimulationObserver interface.
Definition ISimulationObserver.h:57
void notifyHebdoProblem(const PROBLEME_HEBDO &, int, std::string_view) override
The notifyHebdoProblem method is used to notify of a problem during the simulation.
Definition ISimulationObserver.h:61
Definition sim_structure_probleme_economique.h:403