Enum AdStatus

    • Enum Constant Detail

      • DRAFT

        public static final AdStatus DRAFT
        Persisted status. An ad can have this status only if the system is configured to require authorizations. In draft status, only the owner can see and edit the ad.
      • PENDING

        public static final AdStatus PENDING
        Persisted status. An ad can have this status only if the system is configured to require authorizations. The ad is pending for an authorization and cannot be seen by other members.
      • ACTIVE

        public static final AdStatus ACTIVE
        Persisted status but calculated after read from database to ensure it is really active or has already expired/scheduled. The ad is published and can be seen by other members.
      • SCHEDULED

        public static final AdStatus SCHEDULED
        Calculated status (never persisted) according to the publication period. Has a future publication period.
      • EXPIRED

        public static final AdStatus EXPIRED
        Calculated status (never persisted) according to the publication period. Has reached the end of its publication period.
      • HIDDEN

        public static final AdStatus HIDDEN
        Persisted status. Prevents the ad from being seen by other members.
      • DISABLED

        public static final AdStatus DISABLED
        Calculated status (never persisted)
    • Method Detail

      • values

        public static AdStatus[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (AdStatus c : AdStatus.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static AdStatus valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
        NullPointerException - if the argument is null
      • isActive

        public boolean isActive()