Package dev.latvian.mods.klib.math
Record Class SplitBox
java.lang.Object
java.lang.Record
dev.latvian.mods.klib.math.SplitBox
public record SplitBox(Split split, int index, float centerX, float centerY, float centerZ, UV[] uvs, QuadrilaterallyFacedConvexHexahedra shape)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionSplitBox(Split split, int index, float centerX, float centerY, float centerZ, UV[] uvs, QuadrilaterallyFacedConvexHexahedra shape) Creates an instance of aSplitBoxrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfloatcenterX()Returns the value of thecenterXrecord component.floatcenterY()Returns the value of thecenterYrecord component.floatcenterZ()Returns the value of thecenterZrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intindex()Returns the value of theindexrecord component.intkey()shape()Returns the value of theshaperecord component.split()Returns the value of thesplitrecord component.toString()Returns a string representation of this record class.UV[]uvs()Returns the value of theuvsrecord component.
-
Constructor Details
-
SplitBox
public SplitBox(Split split, int index, float centerX, float centerY, float centerZ, UV[] uvs, QuadrilaterallyFacedConvexHexahedra shape) Creates an instance of aSplitBoxrecord class.- Parameters:
split- the value for thesplitrecord componentindex- the value for theindexrecord componentcenterX- the value for thecenterXrecord componentcenterY- the value for thecenterYrecord componentcenterZ- the value for thecenterZrecord componentuvs- the value for theuvsrecord componentshape- the value for theshaperecord 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. -
key
public int key() -
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 '=='. -
split
Returns the value of thesplitrecord component.- Returns:
- the value of the
splitrecord component
-
index
public int index()Returns the value of theindexrecord component.- Returns:
- the value of the
indexrecord component
-
centerX
public float centerX()Returns the value of thecenterXrecord component.- Returns:
- the value of the
centerXrecord component
-
centerY
public float centerY()Returns the value of thecenterYrecord component.- Returns:
- the value of the
centerYrecord component
-
centerZ
public float centerZ()Returns the value of thecenterZrecord component.- Returns:
- the value of the
centerZrecord component
-
uvs
Returns the value of theuvsrecord component.- Returns:
- the value of the
uvsrecord component
-
shape
Returns the value of theshaperecord component.- Returns:
- the value of the
shaperecord component
-