- java.lang.Object
-
- org.spongepowered.math.vector.Vector4i
-
- All Implemented Interfaces:
Serializable
,Comparable<Vector4i>
,Vectori
@Immutable public final class Vector4i extends Object implements Vectori, Comparable<Vector4i>, Serializable
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Vector4i(double x, double y, double z, double w)
Vector4i(int x, int y, int z, int w)
Vector4i(Vector2i v)
Vector4i(Vector2i v, double z, double w)
Vector4i(Vector2i v, int z, int w)
Vector4i(Vector3i v)
Vector4i(Vector3i v, double w)
Vector4i(Vector3i v, int w)
Vector4i(VectorNi v)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Vector4i
abs()
Vector4i
add(double x, double y, double z, double w)
Vector4i
add(int x, int y, int z, int w)
Vector4i
add(Vector4i v)
int
compareTo(Vector4i v)
float
distance(double x, double y, double z, double w)
float
distance(int x, int y, int z, int w)
float
distance(Vector4i v)
int
distanceSquared(double x, double y, double z, double w)
int
distanceSquared(int x, int y, int z, int w)
int
distanceSquared(Vector4i v)
Vector4i
div(double a)
Vector4i
div(double x, double y, double z, double w)
Vector4i
div(int a)
Vector4i
div(int x, int y, int z, int w)
Vector4i
div(Vector4i v)
int
dot(double x, double y, double z, double w)
int
dot(int x, int y, int z, int w)
int
dot(Vector4i v)
boolean
equals(Object other)
static Vector4i
from(int n)
static Vector4i
from(int x, int y, int z, int w)
int
hashCode()
float
length()
int
lengthSquared()
Vector4i
max(double x, double y, double z, double w)
Vector4i
max(int x, int y, int z, int w)
Vector4i
max(Vector4i v)
int
maxAxis()
Return the axis with the maximum value.Vector4i
min(double x, double y, double z, double w)
Vector4i
min(int x, int y, int z, int w)
Vector4i
min(Vector4i v)
int
minAxis()
Return the axis with the minimal value.Vector4i
mul(double a)
Vector4i
mul(double x, double y, double z, double w)
Vector4i
mul(int a)
Vector4i
mul(int x, int y, int z, int w)
Vector4i
mul(Vector4i v)
Vector4i
negate()
Vector4i
pow(double pow)
Vector4i
pow(int power)
Vector4i
project(double x, double y, double z, double w)
Vector4i
project(int x, int y, int z, int w)
Vector4i
project(Vector4i v)
Vector4i
sub(double x, double y, double z, double w)
Vector4i
sub(int x, int y, int z, int w)
Vector4i
sub(Vector4i v)
int[]
toArray()
Vector4d
toDouble()
Vector4f
toFloat()
Vector4i
toInt()
Vector4l
toLong()
String
toString()
Vector2i
toVector2()
Vector3i
toVector3()
VectorNi
toVectorN()
int
w()
int
x()
int
y()
int
z()
-
-
-
Constructor Detail
-
Vector4i
public Vector4i(Vector2i v)
-
Vector4i
public Vector4i(Vector2i v, double z, double w)
-
Vector4i
public Vector4i(Vector2i v, int z, int w)
-
Vector4i
public Vector4i(Vector3i v)
-
Vector4i
public Vector4i(Vector3i v, double w)
-
Vector4i
public Vector4i(Vector3i v, int w)
-
Vector4i
public Vector4i(VectorNi v)
-
Vector4i
public Vector4i(double x, double y, double z, double w)
-
Vector4i
public Vector4i(int x, int y, int z, int w)
-
-
Method Detail
-
x
public int x()
-
y
public int y()
-
z
public int z()
-
w
public int w()
-
add
public Vector4i add(double x, double y, double z, double w)
-
add
public Vector4i add(int x, int y, int z, int w)
-
sub
public Vector4i sub(double x, double y, double z, double w)
-
sub
public Vector4i sub(int x, int y, int z, int w)
-
mul
public Vector4i mul(double a)
-
mul
public Vector4i mul(double x, double y, double z, double w)
-
mul
public Vector4i mul(int x, int y, int z, int w)
-
div
public Vector4i div(double a)
-
div
public Vector4i div(double x, double y, double z, double w)
-
div
public Vector4i div(int x, int y, int z, int w)
-
dot
public int dot(Vector4i v)
-
dot
public int dot(double x, double y, double z, double w)
-
dot
public int dot(int x, int y, int z, int w)
-
project
public Vector4i project(double x, double y, double z, double w)
-
project
public Vector4i project(int x, int y, int z, int w)
-
pow
public Vector4i pow(double pow)
-
min
public Vector4i min(double x, double y, double z, double w)
-
min
public Vector4i min(int x, int y, int z, int w)
-
max
public Vector4i max(double x, double y, double z, double w)
-
max
public Vector4i max(int x, int y, int z, int w)
-
distanceSquared
public int distanceSquared(Vector4i v)
-
distanceSquared
public int distanceSquared(double x, double y, double z, double w)
-
distanceSquared
public int distanceSquared(int x, int y, int z, int w)
-
distance
public float distance(Vector4i v)
-
distance
public float distance(double x, double y, double z, double w)
-
distance
public float distance(int x, int y, int z, int w)
-
lengthSquared
public int lengthSquared()
- Specified by:
lengthSquared
in interfaceVectori
-
minAxis
public int minAxis()
Return the axis with the minimal value.
-
maxAxis
public int maxAxis()
Return the axis with the maximum value.
-
toVector2
public Vector2i toVector2()
-
toVector3
public Vector3i toVector3()
-
toVectorN
public VectorNi toVectorN()
-
compareTo
public int compareTo(Vector4i v)
- Specified by:
compareTo
in interfaceComparable<Vector4i>
-
from
public static Vector4i from(int n)
-
from
public static Vector4i from(int x, int y, int z, int w)
-
-