Enum Class FontWeight

java.lang.Object
java.lang.Enum<FontWeight>
com.webfirmframework.wffweb.css.FontWeight
All Implemented Interfaces:
CssProperty, Serializable, Cloneable, Comparable<FontWeight>, Constable

public enum FontWeight extends Enum<FontWeight> implements CssProperty
 font-weight: normal|bold|bolder|lighter|number|initial|inherit;
 number : 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900

 font-weight: 100 is FontWeight.ONE_HUNDRED, font-weight: 200 is FontWeight.TWO_HUNDRED and so on.
 
Since:
1.0.0
  • Enum Constant Details

    • NORMAL

      public static final FontWeight NORMAL
    • BOLD

      public static final FontWeight BOLD
    • BOLDER

      public static final FontWeight BOLDER
    • LIGHTER

      public static final FontWeight LIGHTER
    • ONE_HUNDRED

      @Deprecated public static final FontWeight ONE_HUNDRED
      Deprecated.
      _100 is available for the same purpose
      use _100 instead of it
    • TWO_HUNDRED

      @Deprecated public static final FontWeight TWO_HUNDRED
      Deprecated.
      _200 is available for the same purpose
      use _200 instead of it
    • THREE_HUNDRED

      @Deprecated public static final FontWeight THREE_HUNDRED
      Deprecated.
      _300 is available for the same purpose
      use _300 instead of it
    • FOUR_HUNDRED

      @Deprecated public static final FontWeight FOUR_HUNDRED
      Deprecated.
      _400 is available for the same purpose
      use _400 instead of it
    • FIVE_HUNDRED

      @Deprecated public static final FontWeight FIVE_HUNDRED
      Deprecated.
      _500 is available for the same purpose
      use _500 instead of it
    • SIX_HUNDRED

      @Deprecated public static final FontWeight SIX_HUNDRED
      Deprecated.
      _600 is available for the same purpose
      use _600 instead of it
    • SEVEN_HUNDRED

      @Deprecated public static final FontWeight SEVEN_HUNDRED
      Deprecated.
      _700 is available for the same purpose
      use _700 instead of it
    • EIGHT_HUNDRED

      @Deprecated public static final FontWeight EIGHT_HUNDRED
      Deprecated.
      _800 is available for the same purpose
      use _800 instead of it
    • NINE_HUNDRED

      @Deprecated public static final FontWeight NINE_HUNDRED
      Deprecated.
      _900 is available for the same purpose
      use _900 instead of it
    • INITIAL

      public static final FontWeight INITIAL
    • INHERIT

      public static final FontWeight INHERIT
    • _100

      public static final FontWeight _100
    • _200

      public static final FontWeight _200
    • _300

      public static final FontWeight _300
    • _400

      public static final FontWeight _400
    • _500

      public static final FontWeight _500
    • _600

      public static final FontWeight _600
    • _700

      public static final FontWeight _700
    • _800

      public static final FontWeight _800
    • _900

      public static final FontWeight _900
  • Method Details

    • values

      public static FontWeight[] 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 FontWeight 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
    • getEnumName

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

      public String toString()
      Overrides:
      toString in class Enum<FontWeight>
    • isValid

      public static boolean isValid(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 FontWeight getThis(String cssValue)
      gets the corresponding object for the given cssValue or null for invalid cssValue.
      Parameters:
      cssValue - the inbuilt cssValue as per w3 standard.
      Returns:
      the corresponding object for the given cssValue or null for invalid cssValue.
      Since:
      1.0.0
    • getCssName

      public String getCssName()
      Specified by:
      getCssName in interface CssProperty
      Returns:
      the name portion in style, eg align-content for style align-content: center.
    • getCssValue

      public String getCssValue()
      Specified by:
      getCssValue in interface CssProperty
      Returns:
      the value portion in style, eg center for style align-content: center.