Enum Class HairStyle

java.lang.Object
java.lang.Enum<HairStyle>
net.fellbaum.jemoji.HairStyle
All Implemented Interfaces:
Serializable, Comparable<HairStyle>, Constable

public enum HairStyle extends Enum<HairStyle>
An enumeration representing different types of hairstyles, each associated with a Unicode character.
  • Enum Constant Details

    • RED_HAIR

      public static final HairStyle RED_HAIR
      Represents red hair as a hairstyle, associated with the Unicode character "🦰".
    • CURLY_HAIR

      public static final HairStyle CURLY_HAIR
      Represents a curly hairstyle, associated with the Unicode character '🦱'.
    • WHITE_HAIR

      public static final HairStyle WHITE_HAIR
      Represents red hair as a hairstyle, associated with the Unicode character "🦳".
    • BALD

      public static final HairStyle BALD
      Represents the "Bald" hairstyle, associated with the Unicode character 🦲.
  • Method Details

    • values

      public static HairStyle[] 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 HairStyle 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
    • getUnicode

      public String getUnicode()
      Gets the Unicode of the hairstyle.
      Returns:
      The Unicode of the hairstyle.
    • isHairStyleEmoji

      public static boolean isHairStyleEmoji(String unicode)
      Check if the given emoji contains a hairstyle element.
      Parameters:
      unicode - The Unicode of the emoji.
      Returns:
      True if the emoji contains a hairstyle element.
    • removeHairStyle

      public static String removeHairStyle(String unicode)
      Removes the hairstyle element from the given emoji.
      Parameters:
      unicode - The Unicode of the emoji.
      Returns:
      The Unicode of the emoji without the hairstyle element.