GENERAL STEPS: ( see modifications that have to be done to this down below)
define a new class called course.java with class atributtes as follow
the default constructor ( should be set courseId =" ", courseTitle = " ", creditHours = 0)
the "init" constructor ( input parameters: courseId, courseTitle, creditHours)
Write a test driver called testCourse.java that instatiates and array of Course objects with the following details:
1st element: courseId="CS101", courseTitle = " Introductory Computer science", credit hours = 3
2nd element: courseId = "CS102" , courseTitle = "Data Structures", creditHours=3
3rd element courseId="CS103", courseTItle="C++ Programing" , creditHours = 4.
the test driver should then display the information on screen on the colums one for course, one for coursetitle and one for credit hours..
MODIFICATIONS THAT NEED TO BE DONE TO MAIN ASSIGMENT:
-All the three attributes – courseId, courseTitle, and creditHours – must be declared by
following the encapsulation principle.
-For each of the three attributes, also write a getter and a setter method.
-At least one of the setter method must use the " this" keyword in its method body.Attachments
add new Course to each member of the array
courses = new Course("CS101", "Introductory Computer Science", 3);
courses = new Course("CS102", "Data Structures", 3);
courses = new Course("CS103",