Package com.vaadin.flow.component
Enum Class KeyLocation
- All Implemented Interfaces:
Serializable
,Comparable<KeyLocation>
,Constable
Possible keyboard key locations.
The location attribute can be used to disambiguate between key values that
can be generated by different physical keys on the keyboard, for example, the
left and right Shift key.
- Since:
- 1.0
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
Gets the key location integer value.static KeyLocation
of
(int location) Returns theKeyLocation
forlocation
.static KeyLocation
Returns the enum constant of this class with the specified name.static KeyLocation[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
STANDARD
Standard key location. -
LEFT
Left key location. -
RIGHT
Right key location. -
NUMPAD
Numeric pad key location.
-
-
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
-
getLocation
public int getLocation()Gets the key location integer value.- Returns:
- the key location integer value
-
of
Returns theKeyLocation
forlocation
.- Parameters:
location
- the location integer value- Returns:
- the
KeyLocation
-