Package com.xpdustry.hexed.generation
Record Class ImmutableSchematic.Tile
java.lang.Object
java.lang.Record
com.xpdustry.hexed.generation.ImmutableSchematic.Tile
- Enclosing class:
- ImmutableSchematic
public static record ImmutableSchematic.Tile(int x, int y, mindustry.world.Block block, @Nullable Object configuration, ImmutableSchematic.Tile.Rotation rotation)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionTile(int x, int y, mindustry.world.Block block, @Nullable Object configuration, ImmutableSchematic.Tile.Rotation rotation) Creates an instance of aTilerecord class. -
Method Summary
Modifier and TypeMethodDescriptionmindustry.world.Blockblock()Returns the value of theblockrecord component.@Nullable ObjectReturns the value of theconfigurationrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.rotation()Returns the value of therotationrecord component.final StringtoString()Returns a string representation of this record class.intx()Returns the value of thexrecord component.inty()Returns the value of theyrecord component.
-
Constructor Details
-
Tile
public Tile(int x, int y, mindustry.world.Block block, @Nullable Object configuration, ImmutableSchematic.Tile.Rotation rotation) Creates an instance of aTilerecord class.- Parameters:
x- the value for thexrecord componenty- the value for theyrecord componentblock- the value for theblockrecord componentconfiguration- the value for theconfigurationrecord componentrotation- the value for therotationrecord 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 '=='. -
x
public int x()Returns the value of thexrecord component.- Returns:
- the value of the
xrecord component
-
y
public int y()Returns the value of theyrecord component.- Returns:
- the value of the
yrecord component
-
block
public mindustry.world.Block block()Returns the value of theblockrecord component.- Returns:
- the value of the
blockrecord component
-
configuration
Returns the value of theconfigurationrecord component.- Returns:
- the value of the
configurationrecord component
-
rotation
Returns the value of therotationrecord component.- Returns:
- the value of the
rotationrecord component
-