Interface RGBLike

  • All Known Subinterfaces:
    TextColor
    All Known Implementing Classes:
    NamedTextColor

    public interface RGBLike
    Something that can provide red, green, and blue colour components.
    Since:
    4.0.0
    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      default @NotNull HSVLike asHSV()
      Converts the color represented by this RGBLike to the HSV color space.
      @org.jetbrains.annotations.Range(from=0L, to=255L) int blue()
      Gets the blue component.
      @org.jetbrains.annotations.Range(from=0L, to=255L) int green()
      Gets the green component.
      @org.jetbrains.annotations.Range(from=0L, to=255L) int red()
      Gets the red component.
    • Method Detail

      • red

        @org.jetbrains.annotations.Range(from=0L, to=255L) int red()
        Gets the red component.
        Returns:
        the red component
        Since:
        4.0.0
      • green

        @org.jetbrains.annotations.Range(from=0L, to=255L) int green()
        Gets the green component.
        Returns:
        the green component
        Since:
        4.0.0
      • blue

        @org.jetbrains.annotations.Range(from=0L, to=255L) int blue()
        Gets the blue component.
        Returns:
        the blue component
        Since:
        4.0.0
      • asHSV

        @NotNull
        default @NotNull HSVLike asHSV()
        Converts the color represented by this RGBLike to the HSV color space.
        Returns:
        an HSVLike representing this RGBLike in the HSV color space
        Since:
        4.6.0