Record Class ResizingComment
java.lang.Object
java.lang.Record
lu.kbra.modelizer_next.ui.canvas.datastruct.ResizingComment
- Record Components:
layout- layout object to read or updateinitialWidth- width valueinitialHeight- height valuestartWorldX- numeric start world x valuestartWorldY- numeric start world y value
public record ResizingComment(NodeLayout layout, double initialWidth, double initialHeight, double startWorldX, double startWorldY)
extends Record
State kept while a comment node is resized.
-
Constructor Summary
ConstructorsConstructorDescriptionResizingComment(NodeLayout layout, double initialWidth, double initialHeight, double startWorldX, double startWorldY) Creates an instance of aResizingCommentrecord 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.doubleReturns the value of theinitialHeightrecord component.doubleReturns the value of theinitialWidthrecord component.layout()Returns the value of thelayoutrecord component.doubleReturns the value of thestartWorldXrecord component.doubleReturns the value of thestartWorldYrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ResizingComment
public ResizingComment(NodeLayout layout, double initialWidth, double initialHeight, double startWorldX, double startWorldY) Creates an instance of aResizingCommentrecord class.- Parameters:
layout- the value for thelayoutrecord componentinitialWidth- the value for theinitialWidthrecord componentinitialHeight- the value for theinitialHeightrecord componentstartWorldX- the value for thestartWorldXrecord componentstartWorldY- the value for thestartWorldYrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
layout
Returns the value of thelayoutrecord component.- Returns:
- the value of the
layoutrecord component
-
initialWidth
public double initialWidth()Returns the value of theinitialWidthrecord component.- Returns:
- the value of the
initialWidthrecord component
-
initialHeight
public double initialHeight()Returns the value of theinitialHeightrecord component.- Returns:
- the value of the
initialHeightrecord component
-
startWorldX
public double startWorldX()Returns the value of thestartWorldXrecord component.- Returns:
- the value of the
startWorldXrecord component
-
startWorldY
public double startWorldY()Returns the value of thestartWorldYrecord component.- Returns:
- the value of the
startWorldYrecord component
-