Enum Class ApplicationStatus

java.lang.Object
java.lang.Enum<ApplicationStatus>
entity.user.ApplicationStatus
All Implemented Interfaces:
Serializable, Comparable<ApplicationStatus>, Constable

public enum ApplicationStatus extends Enum<ApplicationStatus>
Represents the status of an applicant's application for a specific housing project. Defines the possible states throughout the application lifecycle.
  • Enum Constant Details

    • PENDING

      public static final ApplicationStatus PENDING
      The application has been submitted but is awaiting review or processing.
    • SUCCESSFUL

      public static final ApplicationStatus SUCCESSFUL
      The application has been reviewed and approved; the applicant is eligible to proceed (e.g., book a flat).
    • UNSUCCESSFUL

      public static final ApplicationStatus UNSUCCESSFUL
      The application has been reviewed and rejected, or potentially withdrawn by the applicant after approval.
    • BOOKED

      public static final ApplicationStatus BOOKED
      The applicant has successfully booked a specific flat unit after their application was approved.
  • Method Details

    • values

      public static ApplicationStatus[] 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

      public static ApplicationStatus valueOf(String name)
      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 name
      NullPointerException - if the argument is null
    • coloredString

      public String coloredString()
      Returns a string representation of the status, formatted with ANSI escape codes for colored console output.
      • PENDING: Yellow
      • SUCCESSFUL: Green
      • UNSUCCESSFUL: Red
      • BOOKED: Blue
      Note: Color display depends on the console supporting ANSI escape codes.
      Returns:
      A colorized string representation of the enum constant name.