Record Class GuiDragEvent
java.lang.Object
java.lang.Record
dev.boze.api.gui.input.GuiDragEvent
public record GuiDragEvent(double x, double y, int button, double deltaX, double deltaY)
extends Record
Mouse movement with a button held, in GUI-scaled pixels.
-
Constructor Summary
ConstructorsConstructorDescriptionGuiDragEvent(double x, double y, int button, double deltaX, double deltaY) Creates an instance of aGuiDragEventrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintbutton()Returns the value of thebuttonrecord component.doubledeltaX()Returns the value of thedeltaXrecord component.doubledeltaY()Returns the value of thedeltaYrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.doublex()Returns the value of thexrecord component.doubley()Returns the value of theyrecord component.
-
Constructor Details
-
GuiDragEvent
public GuiDragEvent(double x, double y, int button, double deltaX, double deltaY) Creates an instance of aGuiDragEventrecord class.- Parameters:
x- the value for thexrecord componenty- the value for theyrecord componentbutton- the value for thebuttonrecord componentdeltaX- the value for thedeltaXrecord componentdeltaY- the value for thedeltaYrecord 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. -
x
public double x()Returns the value of thexrecord component.- Returns:
- the value of the
xrecord component
-
y
public double y()Returns the value of theyrecord component.- Returns:
- the value of the
yrecord component
-
button
public int button()Returns the value of thebuttonrecord component.- Returns:
- the value of the
buttonrecord component
-
deltaX
public double deltaX()Returns the value of thedeltaXrecord component.- Returns:
- the value of the
deltaXrecord component
-
deltaY
public double deltaY()Returns the value of thedeltaYrecord component.- Returns:
- the value of the
deltaYrecord component
-