1#ifndef HEADER_MODEL_HALL
2#define HEADER_MODEL_HALL
24 Hall(
int number,
unsigned rows,
unsigned seatsPerRow);
34 void read(std::istream& istr);
36 void write(std::ostream& ostr)
const;
std::ostream & operator<<(std::ostream &ostr, const Hall &hall)
Writes Hall to stream with << operator.
Definition: Hall.cpp:74
std::istream & operator>>(std::istream &istr, Hall &hall)
Reads Hall from stream with >> operator.
Definition: Hall.cpp:61
Each hall contains a number, rows and seats per row.
Definition: Hall.h:13
void write(std::ostream &ostr) const
Writes Hall to steam.
Definition: Hall.cpp:44
Hall()
Sets values to 0.
Definition: Hall.cpp:3
int compare(const Hall &other) const
Compare two Halls.
Definition: Hall.cpp:52
unsigned get_seatsPerRow() const
Return a Hall's seats per row count.
Definition: Hall.cpp:20
unsigned get_rows() const
Returns a Hall's row count.
Definition: Hall.cpp:16
int get_number() const
Returns a Hall's number.
Definition: Hall.cpp:13
void read(std::istream &istr)
Reads Hall from stream.
Definition: Hall.cpp:31