Initial commit
[cs356-p1-elevator.git] / stop.cpp
1 #include "stop.hpp"
2
3 Stop::Stop (int floor, enum direction mydirection)
4         : _floor(floor)
5         , _direction(mydirection)
6 {
7         // Intentionally Left Empty
8 }
9
10 bool Stop::operator== (Stop& rhs)
11 {
12         return (_floor == rhs._floor) && (_direction == rhs._direction);
13 }
14
15 bool Stop::lowerThan (Position& rhs)
16 {
17         return (_floor < rhs._floor);
18 }
19
20 bool Stop::higherThan (Position& rhs)
21 {
22         return (_floor > rhs._floor);
23 }
24
25 #if 0
26 bool Stop::operator< (Stop& rhs)
27 {
28         return _floor < rhs._floor;
29 }
30 #endif
31
32 /* vim: set ts=4 sts=4 sw=4 noexpandtab textwidth=112: */