| Enum Constant and Description |
|---|
DOWN |
EAST |
NORTH |
SOUTH |
UNKNOWN |
UP |
WEST |
| Modifier and Type | Field and Description |
|---|---|
static Direction[] |
FLAT_DIRECTIONS
Directions in a 2 dimensional space.
|
org.apache.commons.math3.geometry.euclidean.threed.Rotation |
rotation |
static Direction[] |
VALID_DIRECTIONS
Contains all valid directions.
|
int |
x |
int |
y |
int |
z |
| Modifier and Type | Method and Description |
|---|---|
static Direction |
fromOrdinal(int directionID)
Turns direction number into Direction.
|
static Direction |
fromVector(org.apache.commons.math3.geometry.euclidean.threed.Vector3D unitVector) |
Direction |
opposite() |
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
toVector() |
static Direction |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Direction[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Direction DOWN
public static final Direction UP
public static final Direction NORTH
public static final Direction SOUTH
public static final Direction WEST
public static final Direction EAST
public static final Direction UNKNOWN
public static final Direction[] VALID_DIRECTIONS
public static final Direction[] FLAT_DIRECTIONS
public final int x
public final int y
public final int z
public final org.apache.commons.math3.geometry.euclidean.threed.Rotation rotation
public static Direction[] values()
for (Direction c : Direction.values()) System.out.println(c);
public static Direction valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic static Direction fromOrdinal(int directionID)
directionID - Direction ID / number.java.lang.IllegalArgumentException - if the direction ID is invalid (greater than 6 or less than 0)public static Direction fromVector(org.apache.commons.math3.geometry.euclidean.threed.Vector3D unitVector)
unitVector - The unit vector representing the direction.public Direction opposite()
public org.apache.commons.math3.geometry.euclidean.threed.Vector3D toVector()
Vector3D