public class KeyCodeMap
extends java.lang.Object
Constructor and Description |
---|
KeyCodeMap()
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
int |
getKeyCode(@NotNull java.lang.String keyName)
Returns the key code for a key name.
|
@NotNull java.lang.String |
getKeyName(int keyCode)
Returns the key name for a key code.
|
public int getKeyCode(@NotNull @NotNull java.lang.String keyName) throws NoSuchKeyCodeException
keyName
- the key name to convertNoSuchKeyCodeException
- if the key name is invalid@NotNull public @NotNull java.lang.String getKeyName(int keyCode)
keyCode
- the key code to convert