Class ImmutableColor

java.lang.Object
com.xebisco.yield.Color
com.xebisco.yield.ImmutableColor
All Implemented Interfaces:
Cloneable

public class ImmutableColor extends Color
ImmutableColor class extends the Color class and provides an immutable version of it. It does not allow any of its properties to be changed once they are set.
  • Constructor Details

    • ImmutableColor

      public ImmutableColor(long rgba)
    • ImmutableColor

      public ImmutableColor(Color toCopy)
    • ImmutableColor

      public ImmutableColor(int rgb, double alpha)
    • ImmutableColor

      public ImmutableColor(double red, double green, double blue)
    • ImmutableColor

      public ImmutableColor(double red, double green, double blue, double alpha)
  • Method Details

    • setRed

      public Color setRed(double red)
      Description copied from class: Color
      Setter of the red value of this Color.
      Overrides:
      setRed in class Color
    • setGreen

      public Color setGreen(double green)
      Description copied from class: Color
      Setter of the green value of this Color.
      Overrides:
      setGreen in class Color
    • setBlue

      public Color setBlue(double blue)
      Description copied from class: Color
      Setter of the blue value of this Color.
      Overrides:
      setBlue in class Color
    • setAlpha

      public Color setAlpha(double alpha)
      Description copied from class: Color
      Setter of the alpha value of this Color.
      Overrides:
      setAlpha in class Color