Friday 15 August 2014

c++ - Using all functionality of OOP in three different classes -


I have a homework, I need to make three classes, the student, the professor who receives from the class list of the faculty and I do not know how to chain all OOP functionality (and should), I need to use a template, not an underlying list, I would like to give the dynamic list of students' items and the order of professors of the department to allocate Need, I rewrite the static virtual methods namespace and operators, is why I need to use the virtual Metods? And use namespace? I started it, but I'm in trouble, how to get a good structure to use all the OOP functionality? Thanks for the tips!

Skinny header source code:

  ifndef FACULTATE_H #define FACULTATE_H class faculty {char * nume; & Lt; Profesor * & gt; Profesori; & Lt; Student * & gt; Studenti; Public: Zero addprofesor (); Zero addStudent (); Facultate (); Virtual ~ faculty (); Faculty (faculty and others); Facultate & amp; Operator = (faculty faculty and others); Ostream & amp; Operator & lt; & Lt; (Ostream and O, Cant Consat and F); Protected: private:}; #endif // FACULTATE_H    

There are several ways to organize this.

Here's a layout:

  class person; Class students: public person; Classroom faculty: public person; Class teachers: public faculty; Class staff: public faculty;   

Individual classes have general characteristics for students and teachers, such as first and last names.

No comments:

Post a Comment