Cuboid

public class Cuboid implements Iterable<Position>

Construct a new cuboid that exists of 2 positions

Constructors

Link copied to clipboard
public void Cuboid(Position min, Position max)

Types

Link copied to clipboard
public class Serializer extends TypeAdapter<Cuboid>

Properties

Link copied to clipboard
public Position max
Link copied to clipboard
public Position min

Functions

Link copied to clipboard
public boolean contains(Position position)
Returns true if the given Position is located within the bounds of this cuboid.
Link copied to clipboard
Return all positions contained within this cuboid
Link copied to clipboard
Get the Blocks at the eight corners of the Cuboid.
Link copied to clipboard
public void forEach(Consumer<? super T> action)
Link copied to clipboard
Get the Cuboid big enough to hold both this Cuboid and the given one.
Link copied to clipboard
Get the center of the Cuboid
Link copied to clipboard
public double getHeight()
Returns the cuboid height on the Y axis
Link copied to clipboard
public double getLowerX()
Get the minimum X co-ordinate of this Cuboid
Link copied to clipboard
public double getLowerY()
Get the minimum Y co-ordinate of this Cuboid
Link copied to clipboard
public double getLowerZ()
Get the minimum Z co-ordinate of this Cuboid
Link copied to clipboard
public Position getMax()
Link copied to clipboard
public Position getMin()
Link copied to clipboard
public double getSizeX()
Get the size of this Cuboid along the X axis
Link copied to clipboard
public double getSizeY()
Get the size of this Cuboid along the Y axis
Link copied to clipboard
public double getSizeZ()
Get the size of this Cuboid along the Z axis
Link copied to clipboard
public double getUpperX()
Get the maximum X co-ordinate of this Cuboid
Link copied to clipboard
public double getUpperY()
Get the maximum Y co-ordinate of this Cuboid
Link copied to clipboard
public double getUpperZ()
Get the maximum Z co-ordinate of this Cuboid
Link copied to clipboard
public double getWidthX()
Returns the cuboid width on the X axis
Link copied to clipboard
public double getWidthZ()
Returns the cuboid width on the Z axis
Link copied to clipboard
public Cuboid grow(double delta)
Returns a grown version of this cuboid
public Cuboid grow(double x, double y, double z)
Return a grown version of this cuboid
Link copied to clipboard
Link copied to clipboard
Returns a random position from this Cuboid
Link copied to clipboard
public void setMax(Position max)
Link copied to clipboard
public void setMin(Position min)
Link copied to clipboard
public Cuboid shrink(double delta)
Returns a shrunken version of this cuboid
public Cuboid shrink(double x, double y, double z)
Return a shrunken version of this cuboid
Link copied to clipboard
Link copied to clipboard
public String toString()
Link copied to clipboard
public double volume()
Get the volume of this Cuboid.