Website Summary Files Commits Branches @commit @diff @stats
path: root / src / Models / Hall.cpp
diff options
context:
space:
mode:
Commitb844597fd23bc57aa97e231fc90eecfd6322cecc (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-07 08:28:27 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-07 08:28:27 +0300
Files86a4112ecfa1e3a54dbcf44a7ddf37575ba4aa39 /src/Models/Hall.cpp
FMI-OOP-P1_TicketSystem-b844597fd23bc57aa97e231fc90eecfd6322cecc.tar
FMI-OOP-P1_TicketSystem-b844597fd23bc57aa97e231fc90eecfd6322cecc.tar.gz
FMI-OOP-P1_TicketSystem-b844597fd23bc57aa97e231fc90eecfd6322cecc.zip
Parent0910afb91c8f9672be1d6184f47fb75947ea14f1 (diff)
Reorganized whole architecture
1 files changed, 34 insertions, 0 deletions
-rw-r--r--src/Models/Hall.cpp34
diff --git a/src/Models/Hall.cpp b/src/Models/Hall.cpp
new file mode 100644
index 0000000..98b8cbb
--- /dev/null
+++ b/src/Models/Hall.cpp
@@ -0,0 +1,34 @@
+#include "Hall.h"
+
+Hall::Hall() : Hall(0, 0, 0) {}
+
+Hall::Hall(int index, unsigned rowCount, unsigned seatsPerRow) {
+ this->index = index;
+ this->rowCount = rowCount;
+ this->seatsPerRow = seatsPerRow;
+}
+
+int Hall::get_index() const {
+ return index;
+}
+void Hall::set_index(int index) {
+ this->index = index;
+}
+
+unsigned Hall::get_rowCount() const {
+ return rowCount;
+}
+void Hall::set_rowCount(unsigned rowCount) {
+ this->rowCount = rowCount;
+}
+
+unsigned Hall::get_seatsPerRow() const {
+ return seatsPerRow;
+}
+void Hall::set_seatsPerRow(unsigned seatsPerRow) {
+ this->seatsPerRow = seatsPerRow;
+}
+
+int Hall::compare(const Hall& other) {
+ return (index > other.get_index()) - (index < other.get_index());
+}