public class WrappedChunkCoordinate extends AbstractWrapper implements Comparable<WrappedChunkCoordinate>
handle, handleType| Constructor and Description |
|---|
WrappedChunkCoordinate()
Create a new empty wrapper.
|
WrappedChunkCoordinate(ChunkPosition position)
Create a chunk coordinate wrapper from a given position.
|
WrappedChunkCoordinate(Comparable handle)
Create a wrapper for a specific chunk coordinates.
|
WrappedChunkCoordinate(int x,
int y,
int z)
Create a wrapper with specific values.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(WrappedChunkCoordinate other) |
Object |
getHandle()
Retrieves the underlying NMS object.
|
int |
getX()
Retrieve the x coordinate of the underlying coordinate.
|
int |
getY()
Retrieve the y coordinate of the underlying coordinate.
|
int |
getZ()
Retrieve the z coordinate of the underlying coordinate.
|
void |
setX(int newX)
Set the x coordinate of the underlying coordinate.
|
void |
setY(int newY)
Set the y coordinate of the underlying coordinate.
|
void |
setZ(int newZ)
Set the z coordinate of the underlying coordiate.
|
ChunkPosition |
toPosition()
Create an immutable chunk position from this coordinate.
|
String |
toString() |
equals, getHandleType, hashCode, setHandlepublic WrappedChunkCoordinate()
public WrappedChunkCoordinate(Comparable handle)
handle - - the NMS chunk coordinates.public WrappedChunkCoordinate(int x,
int y,
int z)
x - - the x coordinate.y - - the y coordinate.z - - the z coordinate.public WrappedChunkCoordinate(ChunkPosition position)
position - - the given position.public Object getHandle()
AbstractWrappergetHandle in class AbstractWrapperpublic int getX()
public void setX(int newX)
newX - - the new x coordinate.public int getY()
public void setY(int newY)
newY - - the new y coordinate.public int getZ()
public void setZ(int newZ)
newZ - - the new z coordinate.public ChunkPosition toPosition()
public int compareTo(WrappedChunkCoordinate other)
compareTo in interface Comparable<WrappedChunkCoordinate>public String toString()
toString in class AbstractWrapperCopyright © 2012–2017 Comphenix and dmulloy2. Licensed under the GNU GPL v2.