Antares Simulator
Power System Simulator
Loading...
Searching...
No Matches
statistics.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_LIBS_IO_STATISTICS_H__
22#define __ANTARES_LIBS_IO_STATISTICS_H__
23
24#include <yuni/yuni.h>
25
26namespace Antares
27{
28namespace Statistics
29{
33uint64_t ReadFromDisk();
34
38uint64_t WrittenToDisk();
39
43uint64_t ReadFromDiskSinceStartup();
44
48uint64_t WrittenToDiskSinceStartup();
49
53uint64_t ReadFromNetwork();
54
58uint64_t WrittenToNetwork();
59
63uint64_t ReadFromNetworkSinceStartup();
64
68uint64_t WrittenToNetworkSinceStartup();
69
73void HasReadFromDisk(uint64_t size);
74
78void HasWrittenToDisk(uint64_t size);
79
83void HasReadFromNetwork(uint64_t size);
84
88void HasWrittenToNetwork(uint64_t size);
89
93void Reset();
94
98void DumpToLogs();
99
101{
102public:
103 Updater()
104 {
105 Reset();
106 }
107
108 ~Updater()
109 {
110 DumpToLogs();
111 }
112};
113
115{
116public:
117 LogsDumper()
118 {
119 }
120
122 {
123 DumpToLogs();
124 }
125};
126
127} // namespace Statistics
128} // namespace Antares
129
130#endif // __ANTARES_LIBS_IO_STATISTICS_H__
Definition statistics.h:115
Definition statistics.h:101