#ifndef GRADEBOOK_H_ #define GRADEBOOK_H_ #include #include "Student.h" class StudentNotFound {}; //------------------------------------------------------------------------- /** * This class represents a rudimentary gradebook that contains a set * of student records. It is not very complete yet, but should serve * as an example. * * @author Stephen Edwards * @version Feb 22, 2005 */ class Gradebook { public: //~ Constructor ........................................................... // ---------------------------------------------------------- /** * Creates a new Gradebook object. The gradebook is initially empty. */ Gradebook(); // ---------------------------------------------------------- /** * Destructor. */ virtual ~Gradebook(); //~ Methods ............................................................... // ---------------------------------------------------------- /** * Add another student record to this gradebook. * @param student the new student record to add */ virtual void addStudent( const Student& student ); // ---------------------------------------------------------- /** * Look up a student record by name in this gradebook. * @param name the name of the student to find * @return the student record, if found, or null if no student record * with the given name is found */ virtual Student findStudent( const std::string& name ) const; private: //~ Instance/static variables ............................................. std::vector students; }; #endif /*GRADEBOOK_H_*/