Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Can I get some help finishing the implementations in the comments of this code including the getters and setters for each class as well.. In
Can I get some help finishing the implementations in the comments of this code including the getters and setters for each class as well.. In Java please:
class Student
private int studentId;
private ArrayList listOfCrns;
public Studentint studentId
this.studentId studentId;
this.listOfCrns new ArrayList;
Setters and getters for studentId, studentName, and gpa
public void addCourseint crn
listOfCrns.addcrn;
public void deleteCourseint crn
listOfCrns.removeIntegervalueOfcrn;
private double calculateTotalPayment
Implement the calculation based on the given formula
return ; Placeholder, replace with the actual calculation
public void printInvoice
Implement the printing of the fee invoice based on the given format
Use calculateTotalPayment to get the total amount
class College
private ArrayList list;
public College
this.list new ArrayList;
public void enrollStudentStudent student
Implement adding a student to the list
public boolean searchByIdint studentId
Implement searching for a student by id
return false; Placeholder, replace with the actual implementation
public void addCourseint studentId, int crn
Implement adding a course to the student's list of courses
public boolean deleteCourseint studentId, int crn
Implement deleting a course from the student's list of courses
return false; Placeholder, replace with the actual implementation
public void printInvoiceint studentId
Implement printing the fee invoice for the student
public void printSortedInvoiceint studentId
Implement printing the fee invoice, sorted by course number, for the student
Do not sort the private field listOfCrns of the Student class
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started