Package com.hypixel.hytale.builtin.fluid
Record Class FluidState
java.lang.Object
java.lang.Record
com.hypixel.hytale.builtin.fluid.FluidState
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final FluidState[]private final intThe field for thefluidLevelrecord component.static final intstatic intprivate final byteThe field for theverticalFillrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionFluidState(int fluidLevel, byte verticalFill) Creates an instance of aFluidStaterecord class.FluidState(int fluidLevel, int verticalFill) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.intReturns the value of thefluidLevelrecord component.static FluidState[]generateFluidStates(int maxLevel) final inthashCode()Returns a hash code value for this object.toString()Returns a string representation of this record class.byteReturns the value of theverticalFillrecord component.
-
Field Details
-
fluidLevel
private final int fluidLevelThe field for thefluidLevelrecord component. -
verticalFill
private final byte verticalFillThe field for theverticalFillrecord component. -
SOURCE_LEVEL
public static int SOURCE_LEVEL -
FULL_LEVEL
public static final int FULL_LEVEL- See Also:
-
FLUID_STATES
-
-
Constructor Details
-
FluidState
public FluidState(int fluidLevel, int verticalFill) -
FluidState
public FluidState(int fluidLevel, byte verticalFill) Creates an instance of aFluidStaterecord class.- Parameters:
fluidLevel- the value for thefluidLevelrecord componentverticalFill- the value for theverticalFillrecord component
-
-
Method Details
-
generateFluidStates
-
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 '=='. -
fluidLevel
public int fluidLevel()Returns the value of thefluidLevelrecord component.- Returns:
- the value of the
fluidLevelrecord component
-
verticalFill
public byte verticalFill()Returns the value of theverticalFillrecord component.- Returns:
- the value of the
verticalFillrecord component
-