Overview The objective of this assignment is to demonstrate an ability to implement inheritance, composition, and overloaded operators in a program. This program leverages many of the concepts that...



Overview


The objective of this assignment is to demonstrate an ability to implement inheritance, composition, and overloaded operators in a program.  This program leverages many of the concepts that you have learned in this class and combines them into a professional-style program.



Instructions


Classes are getting to be more realistic with each programming assignment. This assignment includes the valuable aspect of inheritance to facilitate reuse of code and operator overloading to allow the usage of familiar operators tailored specifically to the Person, Student, and Faculty classes. Composition is also demonstrated in the use of a Course class that contains objects of the Student and Faculty classes.


You are working in the IT department for a university and have been tasked with developing an application that will manage the registration process, which involves the creation of a course, the enrollment of students in the course, and the assignment of faculty members to teach the course.



You will need to create several classes to maintain this information:

Course, Person, Student, Faculty, and Date.



The characteristics of Students and Faculty are shown below:



Students:                                                                    Faculty:


ID (string)                                                                   ID (string)


First Name (string)                                                      First Name (string)


Last Name (string)                                                      Last Name (string)


Birthdate (Date)                                                          Birthdate (Date)


Date enrolled (Date)                                                   Date hired (Date)


Major (string)                                                              Title (string)


Level (string) (i.e. Freshman, Sophomore…)             Rank (string)


 GPA (double)                                                             Salary (double)






Several of the data members above require the use of dates.  Strings will not be acceptable substitutes for date fields.





Person


class (base class)


The Person class should contain data members that are common to both Students and Faculty.


Write appropriate member functions to store and retrieve information in the member variables above.  Be sure to include a constructor and destructor.









Student


class
and
Faculty
class. (derived classes)


Both the

Student

and

Faculty

classes should be derived from the

Person

class. Each should have the member variables shown above that are unique to each class.  The data members that are common to both classes should be inherited from the
Person
class.


In each derived class, the
< operator="" should="" be="">
to output, neatly formatted, all of the information associated with a student or faculty member.


The
<>
should be overloaded in the

Student

class to enable sorting of the vector of
Student
objects that will exist in the
Course
class.   You will use the

sort

function to sort this vector.  The

sort

function is part of the
algorithm>

library.


Write member functions to store and retrieve information in the appropriate member variables.  Be sure to include a constructor and destructor in each derived class.







Course


class


The
Course
class has a

name

data member (i.e. a course’s name might be “CSIS 112”).


The class contains a

Faculty object

that represents the Faculty member assigned to teach the class.


The class contains a

vector of Student objects

that represent the students enrolled in the class.


The class has an integer variable,

capacity
, that represents the maximum number of students that can be enrolled in the class.


The
Course
class should support operations to assign a faculty member to the course, enroll students in the course, and list all of the course information, including its name, capacity, instructor, and students enrolled in it.


List of Course Information after assigning two students:<br>Information for Course CSIS 112<br>Instructor:<br>Faculty ID:<br>Faculty Name:<br>Birth Date:<br>Date Hired:<br>Salary:<br>12345<br>Dr. Melesa Poole, Associate Professor<br>1/20/1900<br>6/26/2009<br>1000000000.0e<br>These are the Students enrolled in the CSIS 112 course:<br>Student ID:<br>Student Name:<br>Birth Date:<br>Date Enrolled:<br>Major:<br>11111<br>John Smith<br>5/5/1995<br>12/12/2020<br>Accounting<br>Junior<br>Level:<br>GPA:<br>3.95<br>Student ID:<br>Student Name :<br>Birth Date:<br>Date Enrolled:<br>Major:<br>22222<br>Jane Doe<br>6/22/1997<br>1/1/2020<br>Computer Science<br>Sophomore<br>Level:<br>GPA:<br>3.45<br>Notice that the Students are sorted by IDs in the output above 1<br>

Extracted text: List of Course Information after assigning two students: Information for Course CSIS 112 Instructor: Faculty ID: Faculty Name: Birth Date: Date Hired: Salary: 12345 Dr. Melesa Poole, Associate Professor 1/20/1900 6/26/2009 1000000000.0e These are the Students enrolled in the CSIS 112 course: Student ID: Student Name: Birth Date: Date Enrolled: Major: 11111 John Smith 5/5/1995 12/12/2020 Accounting Junior Level: GPA: 3.95 Student ID: Student Name : Birth Date: Date Enrolled: Major: 22222 Jane Doe 6/22/1997 1/1/2020 Computer Science Sophomore Level: GPA: 3.45 Notice that the Students are sorted by IDs in the output above 1
Main()<br>You should write a main() function that begins by prompting the user for the name and capacity<br>of a course:<br>Enter a name for your Course:<br>CSIS 112<br>What is the maximum capacity for your Course?<br>24<br>Page 3 of 10<br>CSIS 112<br>It should then present a menu to the user that looks like this:<br>Main Menu<br>I -- Add Instructor<br>S -- Add Student<br>L --<br>List Course Information<br>Q --<br>Quit<br>Selection:<br>

Extracted text: Main() You should write a main() function that begins by prompting the user for the name and capacity of a course: Enter a name for your Course: CSIS 112 What is the maximum capacity for your Course? 24 Page 3 of 10 CSIS 112 It should then present a menu to the user that looks like this: Main Menu I -- Add Instructor S -- Add Student L -- List Course Information Q -- Quit Selection: "S" should allow the user to create a Student record and enroll the Stude in the Course. Likewise, "I" should allow the user to create an Instructor (aka Faculty) record and assign the "L" should list ALL of the course information, Faculty member to the course as the instructor. including all of the information about the Students assigned to the course, (sorted by ID number),. as well as all of the information about the faculty member assigned to teach the course. The user should be able to create and assign only ONE faculty member to teach the course, but create and enroll as many Students to the course as the capacity allows. The user should be able to list repeatedly until he or she selects "Q* to quit. Below are some examples of the information that needs to be entered by the user:
Jun 05, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here