In Java code:  Write  course management program that allows professors to create course entries to the course library and student to manage course registration.  Your program will present a menu with the following options: 1. Professor    1.1 creates a course    1.2 show all courses 2. Student    2.1 views a course's details    2.2 enrolls in a course    2.3 drops a course    2.4 shows all enrolled courses 3. Exit Follow these guidelines to define these classes 1. Professor Class Data fields: id, name, courses taught by the professor Constructors: several no-argument, multi-argument constructors Accessor methods that return the values of data fields: return name, courses Mutator methods that set the data fields, e.g, add/remove a course showCourses: list all the courses taught or created by the professor 2.  Student Class Data fields: id, name, gpa, courses enrolled, etc. Constructors: several no-argument, multi-argument constructors Accessor methods that return the values of data fields: return name, courses Mutator methods that set the data fields, e.g, enroll/drop a course showRegistration method: return detailed information about the course the student is enrolled: course id, course name, professor's name, etc. toString(): String representation of the student profile 3.  Course Class  Data fields: id, course name, credit hours, professor's name, max class size, etc. Constructors: several no-argument, multi-argument constructors Accessor methods that return the values of data fields: return course name, credit hours, max size, professor name, etc. Mutator methods that set the data fields, e.g, change class size, name, etc. showRegistration(): all students enrolled in this class toString(): String representation of the course 4.  CourseLibrary Class Data fields: data structure to hold course objects (array, List, Map, etc.) Constructors: several no-argument, multi-argument constructors Accessor methods that return the values of data fields: return Course objects Mutator methods that set the data fields: add/remove courses by name, id, etc.  find method: search for courses by id, name, professor's name showAll(): display all courses

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter11: Advanced Inheritance Concepts
Section: Chapter Questions
Problem 8PE
icon
Related questions
Question

In Java code: 

Write  course management program that allows professors to create course entries to the course library and student to manage course registration. 

Your program will present a menu with the following options:

1. Professor
   1.1 creates a course
   1.2 show all courses
2. Student
   2.1 views a course's details
   2.2 enrolls in a course
   2.3 drops a course
   2.4 shows all enrolled courses
3. Exit

Follow these guidelines to define these classes

1. Professor Class

  • Data fields: id, name, courses taught by the professor
  • Constructors: several no-argument, multi-argument constructors
  • Accessor methods that return the values of data fields: return name, courses
  • Mutator methods that set the data fields, e.g, add/remove a course
  • showCourses: list all the courses taught or created by the professor

2.  Student Class

  • Data fields: id, name, gpa, courses enrolled, etc.
  • Constructors: several no-argument, multi-argument constructors
  • Accessor methods that return the values of data fields: return name, courses
  • Mutator methods that set the data fields, e.g, enroll/drop a course
  • showRegistration method: return detailed information about the course the student is enrolled: course id, course name, professor's name, etc.
  • toString(): String representation of the student profile

3.  Course Class 

  • Data fields: id, course name, credit hours, professor's name, max class size, etc.
  • Constructors: several no-argument, multi-argument constructors
  • Accessor methods that return the values of data fields: return course name, credit hours, max size, professor name, etc.
  • Mutator methods that set the data fields, e.g, change class size, name, etc.
  • showRegistration(): all students enrolled in this class
  • toString(): String representation of the course

4.  CourseLibrary Class

  • Data fields: data structure to hold course objects (array, List, Map, etc.)
  • Constructors: several no-argument, multi-argument constructors
  • Accessor methods that return the values of data fields: return Course objects
  • Mutator methods that set the data fields: add/remove courses by name, id, etc. 
  • find method: search for courses by id, name, professor's name
  • showAll(): display all courses

5. EntryValidator Class

A utility class that helps validate various user input such as name, class name.

6.  CourseManager Class

Define a driver class as the main user interface:

  • Data field: data structure holding course collection (array, list, map, ...)
  • displays option menu
  • takes user input
  • parse user input
  • displays results

7. Any other class deems necessary

These are just the guideline. Your classes need not be exactly as specified. Create additional classes/methods when needed.

Draw a UML class diagram to show your design. To learn about the basics of UML class diagram, find a tutorial on line. 

 

  1. Java source code (.java). Name your file appropriately. Do not compress the files.
  2. A UML class diagram showing class definition and relationships
  3. Test your program with 5+ different sets of input data. Make sure you capture the interactions,
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Development strategies
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT