Enum CssColorName



  • public enum CssColorName
    extends java.lang.Enum<CssColorName>
    Since:
    1.0.0
    • Method Detail

      • values

        public static CssColorName[] values​()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (CssColorName c : CssColorName.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static CssColorName valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getColorName

        public java.lang.String getColorName​()
        Returns:
        the colorName
        Since:
        1.0.0
      • getEnumName

        public java.lang.String getEnumName​()
        Returns:
        the name of this enum.
        Since:
        1.0.0
      • toString

        public java.lang.String toString​()
        Overrides:
        toString in class java.lang.Enum<CssColorName>
      • isValid

        public static boolean isValid​(java.lang.String colorName)
        checks whether the given given colorName is valid , i.e. whether it can have a corresponding object from it.
        Parameters:
        colorName -
        Returns:
        true if the given cssColorName has a corresponding object.
        Since:
        1.0.0
      • getThis

        public static CssColorName getThis​(java.lang.String colorName)
        gets the corresponding object for the given colorName or null for invalid colorName.
        Parameters:
        colorName - the inbuilt color name as per w3 standard.
        Returns:
        the corresponding object for the given colorName or null for invalid colorName.
        Since:
        1.0.0