1 #ifndef MAILSYSTEM_H
2 #define MAILSYSTEM_H
3
4 using namespace std;
5
6 #include <vector>
7 #include <string>
8
9 class Mailbox;
10
11 /**
12 A system of voice mail boxes
13 */
14 class MailSystem
15 {
16 public:
17 /**
18 Constructs a voice mail system with a given number of
19 mailboxes.
20 @param mailbox_count the number of mailboxes
21 */
22 MailSystem(int mailbox_count);
23
24 /**
25 Locate a mailbox.
26 @param ext the extension number
27 @return the mailbox, or NULL if not found
28 */
29 Mailbox* find_mailbox(string ext) const;
30 private:
31 vector<Mailbox*> mailboxes;
32 };
33
34 #endif