Browse Source

Added setter for coursesTaught and improved documentation

remotes/origin/fdai7780
fdai7887 11 months ago
parent
commit
2da89c4761
  1. 13
      src/main/java/org/example/Professor.java

13
src/main/java/org/example/Professor.java

@ -30,6 +30,7 @@ public class Professor {
}
/**
* Constructs a new Professor with the specified ID, name, and role.
*
@ -45,8 +46,18 @@ public class Professor {
}
/**
* Retrieves a List of the professors courses.
*
* @return the unique identifier for the professor
*/
public List<Course> getCoursesTaught() {return coursesTaught;}
/**
* Sets the List of courses taught by the professor to the specified value.
*
* @param coursesTaught the unique identifier for the professor
*/
public void setCoursesTaught(List<Course> coursesTaught) {this.coursesTaught = coursesTaught;}
/**
* Retrieves the professor's ID.

Loading…
Cancel
Save