Enum Class ApprovedStatus
- All Implemented Interfaces:
Serializable,Comparable<ApprovedStatus>,Constable
Represents the approval status of a request that requires explicit approval or rejection,
such as BTO applications, withdrawals, or officer registrations.
This is distinct from the overall processing status (e.g.,
RequestStatus).-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe request is awaiting review and an approval decision (e.g., by a manager).The request has been explicitly approved.The request has been explicitly rejected or deemed unsuccessful. -
Method Summary
Modifier and TypeMethodDescriptionReturns a string representation of the approval status, formatted with ANSI escape codes for colored console output.static ApprovedStatusReturns the enum constant of this class with the specified name.static ApprovedStatus[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
PENDING
The request is awaiting review and an approval decision (e.g., by a manager). -
SUCCESSFUL
The request has been explicitly approved. -
UNSUCCESSFUL
The request has been explicitly rejected or deemed unsuccessful.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
coloredString
Returns a string representation of the approval status, formatted with ANSI escape codes for colored console output.- PENDING: Yellow
- SUCCESSFUL: Green
- UNSUCCESSFUL: Red
- Returns:
- A colorized string representation of the enum constant name.
-