Website Summary Files Commits Branches @commit @diff @stats
path: root / Sem. 06 / Event / Date.h
diff options
context:
space:
mode:
1 files changed, 4 insertions, 3 deletions
-rw-r--r--Sem. 06/Event/Date.h7
diff --git a/Sem. 06/Event/Date.h b/Sem. 06/Event/Date.h
index c1c071f..2e28ffa 100644
--- a/Sem. 06/Event/Date.h
+++ b/Sem. 06/Event/Date.h
@@ -8,10 +8,11 @@ class Date
size_t MAX_DAYS[12] = { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
- int dayOfWeek;
- bool isModified = true;
+ mutable int dayOfWeek;
+ mutable bool isModified = true;
bool isLeapYear() const;
+ void validateDateByChangedCalendars();
public:
Date(size_t day, size_t month, size_t year);
@@ -28,6 +29,6 @@ public:
bool areEqual(const Date& other) const;
- int getDayOfWeek(); //cant be const, because of changings dayOfWeek and isModified
+ int getDayOfWeek() const; //cant be const, because of changings dayOfWeek and isModified
// can we get around this ??
};