| Constructor and Description |
|---|
Vector3Double()
Creates a new Vector2Double with the value (0,0).
|
Vector3Double(double scalar)
Creates a new Vector2 using the scalar to assign the
value (scalar,scalar).
|
Vector3Double(double x,
double y,
double z)
Creates a new Vector2 with the given value.
|
Vector3Double(IVector3 vector)
Creates a new Vector3 with the same value as the input vector.
|
| Modifier and Type | Method and Description |
|---|---|
IVector3 |
add(double scalar)
Adds a scalar to each component of this vector.
|
IVector3 |
add(IVector1 scalar)
Adds a scalar to each component of this vector.
|
IVector3 |
add(IVector3 vector)
Adds another vector to this vector, adding individual components.
|
IVector3 |
assign(IVector3 vector)
Assigns this vector the values of another vector.
|
Object |
clone()
Generates a deep clone of the vector.
|
IVector3 |
copy()
Makes a copy of the vector without using the complex clone interface.
|
IVector3 |
divide(IVector3 vector)
Performs a division on the vector.
|
boolean |
equals(IVector3 vector)
Compares the vector to another vector.
|
boolean |
equals(Object obj)
Compares the vector to an object
|
IVector2 |
getDirection()
Returns the direction (theta) of the vector.
|
IVector1 |
getDistance(IVector3 vector)
Returns the distance to another vector.
|
IVector1 |
getLength()
Returns the length (magnitude) of the vector.
|
static IVector3 |
getVector3(Double x,
Double y,
Double z)
Get a vector for three doubles.
|
IVector1 |
getX()
Returns the x-component of the vector.
|
BigDecimal |
getXAsBigDecimal()
Returns the x-component of the vector as BigDecimal.
|
double |
getXAsDouble()
Returns the x-component of the vector as double.
|
float |
getXAsFloat()
Returns the x-component of the vector as float.
|
int |
getXAsInteger()
Returns the x-component of the vector as integer.
|
long |
getXAsLong()
Returns the x-component of the vector as long.
|
IVector1 |
getY()
Returns the y-component of the vector.
|
BigDecimal |
getYAsBigDecimal()
Returns the component of the vector as BigDecima;.
|
double |
getYAsDouble()
Returns the component of the vector as double.
|
float |
getYAsFloat()
Returns the component of the vector as float.
|
int |
getYAsInteger()
Returns the component of the vector as integer.
|
long |
getYAsLong()
Returns the component of the vector as float.
|
IVector1 |
getZ()
Returns the z-component of the vector.
|
BigDecimal |
getZAsBigDecimal()
Returns the component of the vector as BigDecima;.
|
double |
getZAsDouble()
Returns the component of the vector as double.
|
float |
getZAsFloat()
Returns the component of the vector as float.
|
int |
getZAsInteger()
Returns the component of the vector as integer.
|
long |
getZAsLong()
Returns the component of the vector as float.
|
int |
hashCode()
Compute the hash code.
|
IVector3 |
mod(IVector3 modulus)
Applies a modulo vector.
|
IVector3 |
multiply(double scalar)
Performs a scalar multiplication (scaling) on the vector.
|
IVector3 |
multiply(IVector1 scalar)
Performs a scalar multiplication (scaling) on the vector.
|
IVector3 |
multiply(IVector3 vector)
Performs a multiplication on the vector.
|
IVector3 |
negate()
Negates the vector by negating its components.
|
IVector3 |
negateX()
Negates the x-component.
|
IVector3 |
negateY()
Negates the y-component.
|
IVector3 |
negateZ()
Negates the z-component.
|
IVector3 |
normalize()
Converts the vector to a unit vector (normalization)
|
IVector3 |
randomX(IVector1 lower,
IVector1 upper)
Sets the x-component to a random value in the interval [lower,upper]
|
IVector3 |
randomY(IVector1 lower,
IVector1 upper)
Sets the y-component to a random value in the interval [lower,upper]
|
IVector3 |
randomZ(IVector1 lower,
IVector1 upper)
Sets the z-component to a random value in the interval [lower,upper]
|
void |
setX(IVector1 x) |
void |
setY(IVector1 y) |
void |
setZ(IVector1 z) |
IVector3 |
subtract(double scalar)
Subtracts a scalar to each component of this vector.
|
IVector3 |
subtract(IVector1 scalar)
Subtracts a scalar to each component of this vector.
|
IVector3 |
subtract(IVector3 vector)
Subtracts another vector to this vector, subtracting individual components.
|
String |
toString() |
IVector3 |
zero()
Sets all vector components to zero.
|
public static final IVector3 ZERO
public Vector3Double()
public Vector3Double(IVector3 vector)
public Vector3Double(double scalar)
public Vector3Double(double x,
double y,
double z)
public IVector3 add(double scalar)
IVector3public IVector3 add(IVector1 scalar)
IVector3public IVector3 add(IVector3 vector)
IVector3public IVector3 subtract(double scalar)
IVector3public IVector3 subtract(IVector1 scalar)
IVector3public IVector3 subtract(IVector3 vector)
IVector3public IVector3 mod(IVector3 modulus)
IVector3public IVector3 multiply(double scalar)
IVector3public IVector3 multiply(IVector1 scalar)
IVector3public IVector3 multiply(IVector3 vector)
IVector3public IVector3 zero()
IVector3public IVector3 negateX()
IVector3public IVector3 negateY()
IVector3public IVector3 negateZ()
IVector3public IVector3 negate()
IVector3public IVector3 randomX(IVector1 lower, IVector1 upper)
IVector3public IVector3 randomY(IVector1 lower, IVector1 upper)
IVector3public IVector3 randomZ(IVector1 lower, IVector1 upper)
IVector3public IVector3 normalize()
IVector3public IVector1 getLength()
IVector3public IVector2 getDirection()
IVector3getDirection in interface IVector3public IVector1 getDistance(IVector3 vector)
IVector3getDistance in interface IVector3vector - other vectorpublic IVector1 getX()
IVector3public IVector1 getY()
IVector3public IVector1 getZ()
IVector3public void setX(IVector1 x)
public void setY(IVector1 y)
public void setZ(IVector1 z)
public int getXAsInteger()
getXAsInteger in interface IVector3public int getYAsInteger()
getYAsInteger in interface IVector3public int getZAsInteger()
getZAsInteger in interface IVector3public long getXAsLong()
getXAsLong in interface IVector3public long getYAsLong()
getYAsLong in interface IVector3public long getZAsLong()
getZAsLong in interface IVector3public float getXAsFloat()
IVector3getXAsFloat in interface IVector3public float getYAsFloat()
IVector3getYAsFloat in interface IVector3public float getZAsFloat()
IVector3getZAsFloat in interface IVector3public double getXAsDouble()
IVector3getXAsDouble in interface IVector3public double getYAsDouble()
IVector3getYAsDouble in interface IVector3public double getZAsDouble()
IVector3getZAsDouble in interface IVector3public BigDecimal getXAsBigDecimal()
IVector3getXAsBigDecimal in interface IVector3public BigDecimal getYAsBigDecimal()
IVector3getYAsBigDecimal in interface IVector3public BigDecimal getZAsBigDecimal()
IVector3getZAsBigDecimal in interface IVector3public IVector3 copy()
IVector3public Object clone() throws CloneNotSupportedException
IVector3clone in interface IVector3clone in class ObjectCloneNotSupportedExceptionpublic boolean equals(Object obj)
IVector3public boolean equals(IVector3 vector)
IVector3public int hashCode()
Copyright © 2012. All Rights Reserved.