Record Class EmptyTemplate.Size
java.lang.Object
java.lang.Record
net.neoforged.testframework.gametest.EmptyTemplate.Size
- Enclosing class:
EmptyTemplate
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionSize(int length, int height, int width) Creates an instance of aSizerecord 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.intheight()Returns the value of theheightrecord component.intlength()Returns the value of thelengthrecord component.static EmptyTemplate.SizetoString()Returns a string representation of this record class.intwidth()Returns the value of thewidthrecord component.
-
Field Details
-
length
private final int lengthThe field for thelengthrecord component. -
height
private final int heightThe field for theheightrecord component. -
width
private final int widthThe field for thewidthrecord component.
-
-
Constructor Details
-
Size
public Size(int length, int height, int width) Creates an instance of aSizerecord class.- Parameters:
length- the value for thelengthrecord componentheight- the value for theheightrecord componentwidth- the value for thewidthrecord component
-
-
Method Details
-
parse
-
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. All components in this record class are compared with '=='. -
length
public int length()Returns the value of thelengthrecord component.- Returns:
- the value of the
lengthrecord component
-
height
public int height()Returns the value of theheightrecord component.- Returns:
- the value of the
heightrecord component
-
width
public int width()Returns the value of thewidthrecord component.- Returns:
- the value of the
widthrecord component
-