From 35831ff8dc30c9884a7c3340414f005a0d4ada10 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Thu, 12 May 2022 20:21:09 +0300 Subject: Completely reworked documentation --- docs/html/Reservation_8h_source.html | 124 +++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) create mode 100644 docs/html/Reservation_8h_source.html (limited to 'docs/html/Reservation_8h_source.html') diff --git a/docs/html/Reservation_8h_source.html b/docs/html/Reservation_8h_source.html new file mode 100644 index 0000000..52c470a --- /dev/null +++ b/docs/html/Reservation_8h_source.html @@ -0,0 +1,124 @@ + + + + + + + +FMI Ticket System: src/Models/Reservation.h Source File + + + + + + + + + +
+
+ + + + + + +
+
FMI Ticket System +
+
| Kamen Mladenov | FMI Computer Science Year 1 Group 6 | Project 1 | Project Topic 4 |
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
Reservation.h
+
+
+Go to the documentation of this file.
1#ifndef HEADER_MODEL_RESERVATION
+
2#define HEADER_MODEL_RESERVATION
+
3
+
8#include "Ticket.h"
+
9#include <istream>
+
10#include <ostream>
+
11
+
12#define PASSWORD_LEN 8
+
13#define NOTE_LEN 32
+
14
+ +
18 Ticket ticket;
+
19 char password[PASSWORD_LEN];
+
20 char note[NOTE_LEN];
+
21
+
22public:
+ +
26 Reservation(const Ticket& ticket);
+
28 Reservation(const Ticket& ticket, const char* password, const char* note);
+
29
+
31 const Ticket& get_ticket() const;
+
33 const char* get_password() const;
+
35 const char* get_note() const;
+
36
+
38 void read(std::istream& istr);
+
40 void write(std::ostream& ostr) const;
+
42 int compare(const Reservation& other) const;
+
43
+
45 friend std::istream& operator>>(std::istream& istr, Reservation& reservation);
+
47 friend std::ostream& operator<<(std::ostream& ostr, const Reservation& reservation);
+
48};
+
49
+
50#endif
+
Stores the declaration of class Ticket.
+
Each Reservations contains a ticket, a password and a note.
Definition: Reservation.h:17
+
void read(std::istream &istr)
Reads Reservation from stream.
Definition: Reservation.cpp:34
+
void write(std::ostream &ostr) const
Writes Reservation to stream.
Definition: Reservation.cpp:48
+
const char * get_note() const
Returns constant C-style string to note.
Definition: Reservation.cpp:22
+
friend std::istream & operator>>(std::istream &istr, Reservation &reservation)
Reads Reservation from stream with >> operator.
Definition: Reservation.cpp:66
+
int compare(const Reservation &other) const
Compares two Reservations.
Definition: Reservation.cpp:56
+
Reservation()
Sets ticket as default value and leaves password and note blank.
Definition: Reservation.cpp:4
+
const char * get_password() const
Returns constant C-style string to password.
Definition: Reservation.cpp:18
+
friend std::ostream & operator<<(std::ostream &ostr, const Reservation &reservation)
Writes Reservation to stream with << operator.
Definition: Reservation.cpp:77
+
const Ticket & get_ticket() const
Returns constant reference to ticket.
Definition: Reservation.cpp:14
+
Each Ticket contains a row and a seat number.
Definition: Ticket.h:13
+
+ + + + -- cgit v1.3.1-26-gb76a