Enum Class JohnsonEventLevel

java.lang.Object
java.lang.Enum<JohnsonEventLevel>
com.atlassian.confluence.internal.health.JohnsonEventLevel
All Implemented Interfaces:
Serializable, Comparable<JohnsonEventLevel>, Constable

@ParametersAreNonnullByDefault public enum JohnsonEventLevel extends Enum<JohnsonEventLevel>
The Johnson event levels defined by this product. Motivation: enum values are more typesafe than strings. TestJohnsonEventLevel ensures that this file remains in sync with johnson-config.xml.
Since:
6.5.0
  • Enum Constant Details

  • Method Details

    • values

      public static JohnsonEventLevel[] 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 JohnsonEventLevel 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
    • withName

      public static JohnsonEventLevel withName(String levelName)
      Returns the enum value with the given level name.
      Parameters:
      levelName - the name to match upon (case-insensitively)
      Returns:
      see above
      Throws:
      IllegalArgumentException - if the name is unknown
    • isAtLeast

      public boolean isAtLeast(JohnsonEventLevel minimumLevel)
      Indicates whether this event level is at least as severe as the given level.
      Parameters:
      minimumLevel - the minimum level to check against
      Returns:
      see above
    • levelName

      public @NonNull String levelName()
      Returns the name of the event level for this enum value.
      Returns:
      see above
    • level

      public @NonNull com.atlassian.johnson.event.EventLevel level()
      Returns the Johnson-typed event level for this enum value.
      Returns:
      see above