Record Class PressureTubeBlock.TubeHitInfo
java.lang.Object
java.lang.Record
me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo
- Enclosing class:
- PressureTubeBlock
public static record PressureTubeBlock.TubeHitInfo(net.minecraft.core.Direction dir, me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo.PartType type)
extends Record
Stores information about the subpart of a pressure tube that is being looked at or interacted with.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionTubeHitInfo(net.minecraft.core.Direction dir, me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo.PartType type) Creates an instance of aTubeHitInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.core.Directiondir()Returns the value of thedirrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo.PartTypetype()Returns the value of thetyperecord component.
-
Field Details
-
CENTER
-
-
Constructor Details
-
TubeHitInfo
public TubeHitInfo(net.minecraft.core.Direction dir, me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo.PartType type) Creates an instance of aTubeHitInforecord class.- Parameters:
dir- the value for thedirrecord componenttype- the value for thetyperecord 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. All components in this record class are compared withObjects::equals(Object,Object). -
dir
public net.minecraft.core.Direction dir()Returns the value of thedirrecord component.- Returns:
- the value of the
dirrecord component
-
type
public me.desht.pneumaticcraft.common.block.PressureTubeBlock.TubeHitInfo.PartType type()Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-