diff options
author | Michael Abed <michaelabed@gmail.com> | 2012-04-09 01:45:23 -0400 |
---|---|---|
committer | Michael Abed <michaelabed@gmail.com> | 2012-04-09 01:48:41 -0400 |
commit | 1ba0668dbcf5bc4c40d99ac963711e35797c8efa (patch) | |
tree | b359b81f4e538e923366a7c718d9defd9b823bc4 /Course.h | |
download | ec327-lab3-master.tar.gz ec327-lab3-master.tar.bz2 ec327-lab3-master.zip |
Diffstat (limited to 'Course.h')
-rw-r--r-- | Course.h | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/Course.h b/Course.h new file mode 100644 index 0000000..fa557d1 --- /dev/null +++ b/Course.h @@ -0,0 +1,59 @@ +#ifndef COURSE_H +#define COURSE_H + +#include <string> +using std::string; + +#include "Student.h" +#include "Teacher.h" + +class Teacher; // "Forward declaration" required for compilation. + +/** + * Course class. + */ +class Course +{ +public: + /** + * Default constructor (aka no-argument constructor). + */ + Course(void); + + /** + * This version of the constructor takes the course name and capacity. + */ + Course(string n, int c); + + /** + * Destructor. + */ + ~Course(void); + + void addTeacher(Teacher *t); + void removeTeacher(void); + void addStudent(Student *s); + void removeStudent(Student *s); + void setName(string n); + + Teacher *getTeacher(void); + int getCapacity(void); + int getEnrollmentNumber(void); + string getName(void); + + void printCourse(void); + + friend class Teacher; + +private: + Teacher *teacher; + static const int DEFAULT_CAPACITY = 100; + int capacity; + int enrollmentNumber; + Student **students; + string name; + +}; // class Course; + +#endif // COURSE_H + |