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