Enum Class AnsiColor

java.lang.Object
java.lang.Enum<AnsiColor>
org.springframework.boot.ansi.AnsiColor
All Implemented Interfaces:
Serializable, Comparable<AnsiColor>, Constable, AnsiElement

public enum AnsiColor extends Enum<AnsiColor> implements AnsiElement
Ansi colors.
Since:
1.3.0
Author:
Phillip Webb, Geoffrey Chandler
  • Enum Constant Details

    • DEFAULT

      public static final AnsiColor DEFAULT
    • BLACK

      public static final AnsiColor BLACK
    • RED

      public static final AnsiColor RED
    • GREEN

      public static final AnsiColor GREEN
    • YELLOW

      public static final AnsiColor YELLOW
    • BLUE

      public static final AnsiColor BLUE
    • MAGENTA

      public static final AnsiColor MAGENTA
    • CYAN

      public static final AnsiColor CYAN
    • WHITE

      public static final AnsiColor WHITE
    • BRIGHT_BLACK

      public static final AnsiColor BRIGHT_BLACK
    • BRIGHT_RED

      public static final AnsiColor BRIGHT_RED
    • BRIGHT_GREEN

      public static final AnsiColor BRIGHT_GREEN
    • BRIGHT_YELLOW

      public static final AnsiColor BRIGHT_YELLOW
    • BRIGHT_BLUE

      public static final AnsiColor BRIGHT_BLUE
    • BRIGHT_MAGENTA

      public static final AnsiColor BRIGHT_MAGENTA
    • BRIGHT_CYAN

      public static final AnsiColor BRIGHT_CYAN
    • BRIGHT_WHITE

      public static final AnsiColor BRIGHT_WHITE
  • Method Details

    • values

      public static AnsiColor[] 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 AnsiColor 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
    • toString

      public String toString()
      Specified by:
      toString in interface AnsiElement
      Overrides:
      toString in class Enum<AnsiColor>
      Returns:
      the ANSI escape code