Package main.Utils
Class Authenticator
java.lang.Object
main.Utils.Authenticator
Provide methods to authenticate different user types
The class does not have any public constructors and should be used as a static utility class.
- Since:
- 2023-4-13
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanauthenticateStaff(String username, String password) Method to authenticate staffstatic booleanauthenticateStudent(String username, String password) Method to authenticate student
-
Constructor Details
-
Authenticator
public Authenticator()
-
-
Method Details
-
authenticateStudent
Method to authenticate student- Parameters:
username- userID of studentpassword- password of student- Returns:
- whether the student passed authentication
-
authenticateStaff
Method to authenticate staff- Parameters:
username- userID of staffpassword- password of staff- Returns:
- whether the staff passed authentication
-