Antares Simulator
Power System Simulator
Loading...
Searching...
No Matches
xcast.h
1/*
2** Copyright 2007-2024, RTE (https://www.rte-france.com)
3** See AUTHORS.txt
4** SPDX-License-Identifier: MPL-2.0
5** This file is part of Antares-Simulator,
6** Adequacy and Performance assessment for interconnected energy networks.
7**
8** Antares_Simulator is free software: you can redistribute it and/or modify
9** it under the terms of the Mozilla Public Licence 2.0 as published by
10** the Mozilla Foundation, either version 2 of the License, or
11** (at your option) any later version.
12**
13** Antares_Simulator is distributed in the hope that it will be useful,
14** but WITHOUT ANY WARRANTY; without even the implied warranty of
15** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16** Mozilla Public Licence 2.0 for more details.
17**
18** You should have received a copy of the Mozilla Public Licence 2.0
19** along with Antares_Simulator. If not, see <https://opensource.org/license/mpl-2-0/>.
20*/
21#ifndef __ANTARES_WINDOWS_XCAST_XCAST_H__
22#define __ANTARES_WINDOWS_XCAST_XCAST_H__
23
24#include "../../toolbox/components/notebook/notebook.h"
25#include "../../toolbox/components/datagrid/component.h"
26#include "../../toolbox/input/area.h"
27#include <yuni/core/event.h>
28#include <antares/study/study.h>
29#include <wx/stattext.h>
30#include <wx/sizer.h>
31#include <wx/checkbox.h>
32#include <wx/choice.h>
33
34namespace Antares
35{
36namespace Window
37{
38template<enum Data::TimeSeriesType T>
39class XCast final : public wxPanel, public Yuni::IEventObserver<XCast<T>>
40{
41public:
45 using ObserverAncestorType = Yuni::IEventObserver<XCast<T>>;
46
47public:
49
50
53 XCast(wxWindow* parent, Toolbox::InputSelector::Area* notifier);
57 virtual ~XCast();
59
60 void selectDefaultPage();
61
62private:
64 void onStudyClosed();
66 void onAreaChanged(Data::Area* area);
68 void onInstalledCapacityChanged(wxCommandEvent& evt);
70 void onUpdateDistribution(wxCommandEvent& evt);
72 void onUpdateTSTranslationUse(wxCommandEvent& evt);
74 void onUpdateConversion(wxCommandEvent& evt);
75
76private:
80 Data::Area* pArea;
82 wxTextCtrl* pInstalledCapacity;
83 wxChoice* pDistribution;
84 wxCheckBox* useConversion;
85 wxChoice* useTranslation;
86
87 Component::Notebook* pNotebook;
88 //
89 Component::Notebook::Page* pPageDailyProfile;
90 Component::Notebook::Page* pPageGeneral;
91 Component::Notebook::Page* pPageTranslation;
92
94
95}; // class XCast
96
97} // namespace Window
98} // namespace Antares
99
100#include "xcast.hxx"
101
102#endif // __ANTARES_WINDOWS_XCAST_XCAST_H__
A datagrid with virtual values.
Definition component.h:84
Definition notebook.h:62
Notebook.
Definition notebook.h:38
Definition for a single area.
Definition area.h:52
Visual Component for displaying all available areas (and groups)
Definition area.h:41
Definition xcast.h:40
Yuni::IEventObserver< XCast< T > > ObserverAncestorType
The Observer ancestor type.
Definition xcast.h:45
XCast(wxWindow *parent, Toolbox::InputSelector::Area *notifier)
Default constructor.
Definition xcast.hxx:40
virtual ~XCast()
Destructor.
Definition xcast.hxx:187