Package sc2002.FCS1.grp2
Class ApplicantActions
Object
ApplicantActions
- All Implemented Interfaces:
IUserActions
Handles all actions specific to users logged in with applicant role.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidapplyBTOFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) Flow for applying BTO project, for both applicants and hdb officers.(package private) static voideditEnquiry(SuperScanner superScanner, EnquiriesSystem enquiriesSystem, Enquiry selectedEnquiry) private static voidenterEnquiriesSystem(Applicant applicant) static voidhandleAction(Applicant.Menu option, Applicant user) Point of entry, to be handed over fromBTOManagementApplicationprivate static booleanprintApplicationsTable(List<Application> applications) Method to print the application that applicant have applied, if any.(package private) static voidremoveEnquiry(Enquiry selectedEnquiry, EnquiriesSystem enquiriesSystem) private static voidrepeatableMenuFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) this is the menu display which will be displayed at the home page for applicants.private static EnquiryretrieveEnquiryFromUser(SuperScanner superScanner, EnquiriesSystem enquiriesSystem) private static voidsearchFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) Flow to search for a project(package private) static voidsendEnquiryFlow(Applicant applicant) (package private) static voidviewApplication(Applicant applicant) Action flow for an applicant to view BTO applications applied.private static voidviewProjects(Applicant applicant) Method for user to view all the available projects for user to apply, filtered based on the user's age and marital status.(package private) static voidwithdrawalApplicationFlow(Applicant applicant) The flow for withdrawing of application
-
Field Details
-
system
-
-
Constructor Details
-
ApplicantActions
public ApplicantActions()
-
-
Method Details
-
handleAction
Point of entry, to be handed over fromBTOManagementApplication- Parameters:
option- Menu option selected by user.user- The user involved in the current action.- Throws:
Exception
-
withdrawalApplicationFlow
The flow for withdrawing of application- Parameters:
applicant-- Throws:
Exception
-
printApplicationsTable
Method to print the application that applicant have applied, if any.- Parameters:
applications-- Returns:
-
viewApplication
Action flow for an applicant to view BTO applications applied.- Parameters:
applicant- The applicant that is actively using the application at current.- Throws:
Exception
-
viewProjects
Method for user to view all the available projects for user to apply, filtered based on the user's age and marital status.- Parameters:
applicant-- Throws:
Exception
-
repeatableMenuFlow
private static void repeatableMenuFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) throws Exception this is the menu display which will be displayed at the home page for applicants.- Parameters:
applicant-projects-sscanner-- Throws:
Exception
-
searchFlow
private static void searchFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) throws Exception Flow to search for a project- Parameters:
applicant- applicant thats trying to search a projectprojects- applicable projectssscanner- scanner for user input.- Throws:
Exception- access control, etc
-
applyBTOFlow
public static void applyBTOFlow(Applicant applicant, ArrayList<BTOProject> projects, SuperScanner sscanner) throws Exception Flow for applying BTO project, for both applicants and hdb officers.- Parameters:
applicant- The applicant thats applying for projectprojects- Projects that applicant can applysscanner- The scanner- Throws:
Exception- access control, etc.
-
enterEnquiriesSystem
- Throws:
Exception
-
retrieveEnquiryFromUser
private static Enquiry retrieveEnquiryFromUser(SuperScanner superScanner, EnquiriesSystem enquiriesSystem) -
removeEnquiry
static void removeEnquiry(Enquiry selectedEnquiry, EnquiriesSystem enquiriesSystem) throws Exception - Throws:
Exception
-
editEnquiry
static void editEnquiry(SuperScanner superScanner, EnquiriesSystem enquiriesSystem, Enquiry selectedEnquiry) throws Exception - Throws:
Exception
-
sendEnquiryFlow
- Throws:
Exception
-