3 #include <QtWidgets/QWidget>
8 #include <unordered_map>
9 #include "qtcsv/stringdata.h"
10 #include "qtcsv/reader.h"
11 #include "qtcsv/writer.h"
13 #include <qvector3d.h>
16 namespace fs = std::filesystem;
49 return std::to_string(
day) +
"." + std::to_string(
month) +
"." + std::to_string(
year);
67 return (hash<int>()(d.
year) << 1)
68 ^ (hash<int>()(d.
month) << 1)
69 ^ (hash<int>()(d.
day) << 1);
91 int decideLimit(
int year,
int month);
98 void initData(std::string filespath);
121 std::unordered_map<Date, std::vector<std::vector<std::string>>>
data;
127 std::unordered_map<std::string, std::pair<float, float>>
minMax;
A Calendar from which you can access the whole data.
Definition: Calendar.h:83
std::unordered_map< Date, std::vector< std::vector< std::string > > > data
Definition: Calendar.h:121
~Calendar()
Destructor.
Definition: Calendar.cpp:29
std::unordered_map< std::string, QVector3D > entity_colors
Definition: Calendar.h:143
std::unordered_map< std::string, std::pair< float, float > > minMax
Definition: Calendar.h:127
Date minDate
Definition: Calendar.h:116
std::unordered_map< std::string, int > attr_to_index_map
Definition: Calendar.h:137
Date addDaysToDate(Date date, int daysToAdd)
Adds the days to date to 'daysToAdd'.
Definition: Calendar.cpp:93
Calendar(std::string filespath)
Constructor.
Definition: Calendar.cpp:14
std::vector< std::string > attribute_names
Definition: Calendar.h:132
Date maxDate
Definition: Calendar.h:116
Definition: Calendar.h:53
representing a Date
Definition: Calendar.h:27
Date(int y, int m, int d)
Definition: Calendar.h:31
int year
Definition: Calendar.h:28
bool operator<(const Date &o) const
Definition: Calendar.h:44
Date()
Definition: Calendar.h:29
int month
Definition: Calendar.h:28
int day
Definition: Calendar.h:28
bool operator==(const Date &o) const
Definition: Calendar.h:40
std::string toString()
Definition: Calendar.h:48
std::size_t operator()(const Date &d) const
Definition: Calendar.h:58