Enum Class GitDiffColor

java.lang.Object
java.lang.Enum<GitDiffColor>
com.atlassian.bitbucket.scm.git.command.diff.GitDiffColor
All Implemented Interfaces:
Serializable, Comparable<GitDiffColor>, Constable

public enum GitDiffColor extends Enum<GitDiffColor>
Enumerates the possible modes for git diff-core --color.
  • Enum Constant Details

    • ALWAYS

      public static final GitDiffColor ALWAYS
      Always include color markers in the diff output.
    • AUTO

      public static final GitDiffColor AUTO
      Automatically turn color markers in diff output on when connected to a terminal.

      Warning: This value is included for completeness in enumerating Git's supported color modes. However, it functions the same as NEVER, here, since the system is not a terminal.

    • DEFAULT

      public static final GitDiffColor DEFAULT
      Uses the .gitconfig-configured setting for color markers in diff output.
    • NEVER

      public static final GitDiffColor NEVER
      Never include color markers in the diff output, even if it is configured in .gitconfig.
  • Method Details

    • values

      public static GitDiffColor[] 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 GitDiffColor 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
    • getFlag

      public String getFlag()
    • isFlagged

      public boolean isFlagged()