Package com.oorian.html.elements.consts
Enum Class TextDirection
- All Implemented Interfaces:
Serializable,Comparable<TextDirection>,Constable
Enumeration defining text directionality for HTML elements.
This enum provides type-safe constants for the "dir" attribute, which specifies
the text direction for content within an element.
- Since:
- 1.0
- Version:
- 1.0
- Author:
- Marvin P. Warble Jr.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptiongetValue()Gets the text direction value for use in HTML dir attribute.toString()static TextDirectionReturns the enum constant of this class with the specified name.static TextDirection[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
LTR
Left-to-right text direction. Used for languages like English, French, and most European languages. -
RTL
Right-to-left text direction. Used for languages like Arabic, Hebrew, and Persian.
-
-
Method Details
-
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
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 nameNullPointerException- if the argument is null
-
getValue
Gets the text direction value for use in HTML dir attribute.- Returns:
- the string value used in HTML dir attribute.
-
toString
- Overrides:
toStringin classEnum<TextDirection>
-