Module sc2002_fypms
Package services

Class ProjectSupervisorService

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean createProjects​(java.util.ArrayList<Project> projects)
      Creates new projects from the provided list of projects.
      java.util.ArrayList<Project> getSubmittedProjects​(java.lang.String supervisorID)
      Retrieves a list of projects submitted by the supervisor with the specified ID.
      boolean updateProjectTitle​(Project project, java.lang.String title, java.lang.String supervisorID)
      Updates the title of the specified project if the supervisor ID matches the project's supervisor.
      boolean updateRemainingProjectsToUnavailable​(java.lang.String supervisorID)
      Updates the remaining projects of the specified supervisor to unavailable.
      boolean updateUnavailableProjectsToAvailable​(java.lang.String supervisorID)
      Updates the unavailable projects of the specified supervisor to available.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ProjectSupervisorService

        public ProjectSupervisorService()
        Constructs an instance of the ProjectSupervisorService class.
    • Method Detail

      • getSubmittedProjects

        public java.util.ArrayList<Project> getSubmittedProjects​(java.lang.String supervisorID)
        Description copied from interface: IProjectSupervisorService
        Retrieves a list of projects submitted by the supervisor with the specified ID.
        Specified by:
        getSubmittedProjects in interface IProjectSupervisorService
        Parameters:
        supervisorID - the ID of the supervisor
        Returns:
        an ArrayList of Project objects representing the submitted projects
      • createProjects

        public boolean createProjects​(java.util.ArrayList<Project> projects)
        Description copied from interface: IProjectSupervisorService
        Creates new projects from the provided list of projects.
        Specified by:
        createProjects in interface IProjectSupervisorService
        Parameters:
        projects - an ArrayList of Project objects to be created
        Returns:
        true if the projects were created successfully, false otherwise
      • updateProjectTitle

        public boolean updateProjectTitle​(Project project,
                                          java.lang.String title,
                                          java.lang.String supervisorID)
        Description copied from interface: IProjectSupervisorService
        Updates the title of the specified project if the supervisor ID matches the project's supervisor.
        Specified by:
        updateProjectTitle in interface IProjectSupervisorService
        Parameters:
        project - the Project object to update
        title - the new title for the project
        supervisorID - the ID of the supervisor making the update
        Returns:
        true if the project title was updated successfully, false otherwise
      • updateRemainingProjectsToUnavailable

        public boolean updateRemainingProjectsToUnavailable​(java.lang.String supervisorID)
        Description copied from interface: IProjectSupervisorService
        Updates the remaining projects of the specified supervisor to unavailable.
        Specified by:
        updateRemainingProjectsToUnavailable in interface IProjectSupervisorService
        Parameters:
        supervisorID - the ID of the supervisor
        Returns:
        true if the remaining projects were updated successfully, false otherwise
      • updateUnavailableProjectsToAvailable

        public boolean updateUnavailableProjectsToAvailable​(java.lang.String supervisorID)
        Description copied from interface: IProjectSupervisorService
        Updates the unavailable projects of the specified supervisor to available.
        Specified by:
        updateUnavailableProjectsToAvailable in interface IProjectSupervisorService
        Parameters:
        supervisorID - the ID of the supervisor
        Returns:
        true if the unavailable projects were updated successfully, false otherwise