Enum Class EnvironmentScope

java.lang.Object
java.lang.Enum<EnvironmentScope>
net.ygbstudio.powerwp4j.base.extension.enums.EnvironmentScope
All Implemented Interfaces:
Serializable, Comparable<EnvironmentScope>, Constable, FriendlyEnum

public enum EnvironmentScope extends Enum<EnvironmentScope> implements FriendlyEnum
Enumeration that represents the keys for the environment variables required to connect to a WordPress site.

This enum implements the FriendlyEnum interface to enforce a user-friendly string representation of the enum constants.

Author:
Yoham Gabriel @ YGBStudio
  • Enum Constant Details

    • WP_USER_PROP

      public static final EnvironmentScope WP_USER_PROP
      wp.user property key.
    • WP_APPLICATION_PASS_PROP

      public static final EnvironmentScope WP_APPLICATION_PASS_PROP
      wp.appPass property key.
    • WP_FULLY_QUALIFIED_DOMAIN_NAME_PROP

      public static final EnvironmentScope WP_FULLY_QUALIFIED_DOMAIN_NAME_PROP
      wp.fqdn property key.
    • WP_USER_ENV

      public static final EnvironmentScope WP_USER_ENV
      WP_USER environment variable.
    • WP_APPLICATION_PASS_ENV

      public static final EnvironmentScope WP_APPLICATION_PASS_ENV
      WP_APP_PASS environment variable.
    • WP_FULLY_QUALIFIED_DOMAIN_NAME_ENV

      public static final EnvironmentScope WP_FULLY_QUALIFIED_DOMAIN_NAME_ENV
      WP_FQDN environment variable.
  • Method Details

    • values

      public static EnvironmentScope[] 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 EnvironmentScope 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
    • value

      public String value()
      Description copied from interface: FriendlyEnum
      Returns the value of the enum constant, which is the actual string to be used in the API.

      Example: If an enum constant is named STATUS_PENDING, the value returned by this method would be "pending", which is the value provided in its constructor.

      Specified by:
      value in interface FriendlyEnum
      Returns:
      the value of the enum constant