Record Class KeyPressEvent
java.lang.Object
java.lang.Record
com.stereowalker.unionlib.api.gui.KeyPressEvent
-
Constructor Summary
ConstructorsConstructorDescriptionKeyPressEvent(int keyCode, int scanCode, int modifiers) Creates an instance of aKeyPressEventrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intkeyCode()Returns the value of thekeyCoderecord component.intReturns the value of themodifiersrecord component.intscanCode()Returns the value of thescanCoderecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
KeyPressEvent
public KeyPressEvent(int keyCode, int scanCode, int modifiers) Creates an instance of aKeyPressEventrecord class.- Parameters:
keyCode- the value for thekeyCoderecord componentscanCode- the value for thescanCoderecord componentmodifiers- the value for themodifiersrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
keyCode
public int keyCode()Returns the value of thekeyCoderecord component.- Returns:
- the value of the
keyCoderecord component
-
scanCode
public int scanCode()Returns the value of thescanCoderecord component.- Returns:
- the value of the
scanCoderecord component
-
modifiers
public int modifiers()Returns the value of themodifiersrecord component.- Returns:
- the value of the
modifiersrecord component
-