Enum Class ColorPaletteAlgorithms

java.lang.Object
java.lang.Enum<ColorPaletteAlgorithms>
io.deephaven.gui.color.ColorPaletteAlgorithms
All Implemented Interfaces:
ColorPaletteAlgorithm, Serializable, Comparable<ColorPaletteAlgorithms>, java.lang.constant.Constable

public enum ColorPaletteAlgorithms extends Enum<ColorPaletteAlgorithms> implements ColorPaletteAlgorithm
  • Enum Constant Details

    • GOLDEN

      public static final ColorPaletteAlgorithms GOLDEN
      Golden ratio algorithm. Rotates hue values by the inverse golden ratio.
    • TRIAD_MIXING

      public static final ColorPaletteAlgorithms TRIAD_MIXING
      Triad mixing algorithm. Randomly generates and mixes 3 colors and their RGB components.
  • Method Details

    • values

      public static ColorPaletteAlgorithms[] 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 ColorPaletteAlgorithms 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
    • nextColor

      public Color nextColor(Color c)
      Description copied from interface: ColorPaletteAlgorithm
      Gets the next Color after c in the algorithm.
      Specified by:
      nextColor in interface ColorPaletteAlgorithm
      Parameters:
      c - color
      Returns:
      result of plugging c in the algorithm
    • getInitialColor

      public Color getInitialColor()
      Description copied from interface: ColorPaletteAlgorithm
      Gets the algorithm's starting Color.
      Specified by:
      getInitialColor in interface ColorPaletteAlgorithm
      Returns:
      algorithm's starting Color
    • colorPaletteAlgorithm

      public static ColorPaletteAlgorithms colorPaletteAlgorithm(String name)
      Gets the algorithm corresponding to the given name.
      Parameters:
      name - case insensitive algorithm descriptor
      Returns:
      algorithm corresponding to the given name
      Throws:
      IllegalArgumentException - name must not be null
    • colorPaletteAlgorithmNames

      public static String[] colorPaletteAlgorithmNames()
      Gets the names of the available ColorPaletteAlgorithms.
      Returns:
      array of the available ColorPaletteAlgorithms names