Package net.minecraft.server.level
Record Class ColumnPos
java.lang.Object
java.lang.Record
net.minecraft.server.level.ColumnPos
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate static final longprivate static final longprivate final intThe field for thexrecord component.private final intThe field for thezrecord component.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic longasLong(int p_143198_, int p_143199_) final booleanIndicates whether some other object is "equal to" this one.static intgetX(long p_214970_) static intgetZ(long p_214972_) inthashCode()Returns a hash code value for this object.longtoLong()toString()Returns a string representation of this record class.intx()Returns the value of thexrecord component.intz()Returns the value of thezrecord component.
- 
Field Details- 
xprivate final int xThe field for thexrecord component.
- 
zprivate final int zThe field for thezrecord component.
- 
COORD_BITSprivate static final long COORD_BITS- See Also:
 
- 
COORD_MASKprivate static final long COORD_MASK- See Also:
 
 
- 
- 
Constructor Details- 
ColumnPospublic ColumnPos(int x, int z) Creates an instance of aColumnPosrecord class.- Parameters:
- x- the value for the- xrecord component
- z- the value for the- zrecord component
 
 
- 
- 
Method Details- 
toChunkPos
- 
toLongpublic long toLong()
- 
asLongpublic static long asLong(int p_143198_, int p_143199_) 
- 
getXpublic static int getX(long p_214970_) 
- 
getZpublic static int getZ(long p_214972_) 
- 
toStringReturns 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.
- 
hashCodepublic int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
- 
equalsIndicates 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 '=='.
- 
xpublic int x()Returns the value of thexrecord component.- Returns:
- the value of the xrecord component
 
- 
zpublic int z()Returns the value of thezrecord component.- Returns:
- the value of the zrecord component
 
 
-