Class InnerComputationVector2afp
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d2.afp.InnerComputationVector2afp
-
- All Implemented Interfaces:
Serializable
,Cloneable
,Tuple2D<InnerComputationVector2afp>
,Vector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
,JsonableObject
public class InnerComputationVector2afp extends Object implements Vector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
A vector that is used for internal computations.- Since:
- 13.0
- Version:
- 17.0 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND
- See Also:
- Serialized Form
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.arakhne.afc.math.geometry.d2.Vector2D
Vector2D.PowerResult<T extends Vector2D<? super T,?>>
-
-
Constructor Summary
Constructors Constructor Description InnerComputationVector2afp()
Construct vector.InnerComputationVector2afp(double x, double y)
Construct vector.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description InnerComputationVector2afp
clone()
Clone this point.InnerComputationGeomFactory
getGeomFactory()
Replies the geometry factory associated to this point.double
getX()
Get the x coordinate.double
getY()
Get the y coordinate.int
ix()
Get the x coordinate.int
iy()
Get the y coordinate.void
setX(double x)
Set the x coordinate.void
setX(int x)
Set the x coordinate.void
setY(double y)
Set the y coordinate.void
setY(int y)
Set the y coordinate.void
toJson(JsonBuffer buffer)
Replies the Json representation of this node.InnerComputationVector2afp
toOrthogonalVector()
Replies the orthogonal vector to this vector.String
toString()
InnerComputationVector2afp
toUnitVector()
Replies the unit vector of this vector.UnmodifiableVector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
toUnmodifiable()
Replies an unmodifiable copy of this vector.-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.arakhne.afc.math.geometry.d2.Tuple2D
absolute, absolute, add, add, addX, addX, addY, addY, clamp, clamp, clamp, clamp, clampMax, clampMax, clampMax, clampMax, clampMin, clampMin, clampMin, clampMin, epsilonEquals, equals, equals, get, get, get, hashCode, interpolate, interpolate, negate, negate, scale, scale, scale, scale, set, set, set, set, set, sub, sub, subX, subX, subY, subY
-
Methods inherited from interface org.arakhne.afc.math.geometry.d2.Vector2D
$div, $minus, $minus, $minus, $minus, $plus, $plus, $plus, $times, $times, $up, $up, add, add, angle, dot, getLength, getLengthSquared, getOrientationAngle, isOrthogonal, isUnitVector, makeOrthogonal, normalize, normalize, operator_add, operator_divide, operator_doubleDotLessThan, operator_elvis, operator_equals, operator_greaterThanDoubleDot, operator_minus, operator_minus, operator_minus, operator_minus, operator_multiply, operator_multiply, operator_notEquals, operator_plus, operator_plus, operator_plus, operator_power, operator_power, operator_remove, operator_upTo, perp, power, scaleAdd, scaleAdd, scaleAdd, scaleAdd, setLength, signedAngle, sub, sub, sub, toColinearVector, turn, turn, turnLeft, turnLeft, turnLeft, turnRight, turnRight
-
-
-
-
Method Detail
-
getGeomFactory
public InnerComputationGeomFactory getGeomFactory()
Description copied from interface:Vector2D
Replies the geometry factory associated to this point.- Specified by:
getGeomFactory
in interfaceVector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
- Returns:
- the factory.
-
toJson
public void toJson(JsonBuffer buffer)
Description copied from interface:JsonableObject
Replies the Json representation of this node.- Specified by:
toJson
in interfaceJsonableObject
- Parameters:
buffer
- the Json buffer.
-
clone
public InnerComputationVector2afp clone()
Description copied from interface:Tuple2D
Clone this point.- Specified by:
clone
in interfaceTuple2D<InnerComputationVector2afp>
- Overrides:
clone
in classObject
- Returns:
- the clone.
-
getX
public double getX()
Description copied from interface:Tuple2D
Get the x coordinate.- Specified by:
getX
in interfaceTuple2D<InnerComputationVector2afp>
- Returns:
- the x coordinate.
-
ix
public int ix()
Description copied from interface:Tuple2D
Get the x coordinate.- Specified by:
ix
in interfaceTuple2D<InnerComputationVector2afp>
- Returns:
- the x coordinate.
-
setX
public void setX(int x)
Description copied from interface:Tuple2D
Set the x coordinate.- Specified by:
setX
in interfaceTuple2D<InnerComputationVector2afp>
- Parameters:
x
- value to x coordinate.
-
setX
public void setX(double x)
Description copied from interface:Tuple2D
Set the x coordinate.- Specified by:
setX
in interfaceTuple2D<InnerComputationVector2afp>
- Parameters:
x
- value to x coordinate.
-
getY
public double getY()
Description copied from interface:Tuple2D
Get the y coordinate.- Specified by:
getY
in interfaceTuple2D<InnerComputationVector2afp>
- Returns:
- the y coordinate.
-
iy
public int iy()
Description copied from interface:Tuple2D
Get the y coordinate.- Specified by:
iy
in interfaceTuple2D<InnerComputationVector2afp>
- Returns:
- the y coordinate.
-
setY
public void setY(int y)
Description copied from interface:Tuple2D
Set the y coordinate.- Specified by:
setY
in interfaceTuple2D<InnerComputationVector2afp>
- Parameters:
y
- value to y coordinate.
-
setY
public void setY(double y)
Description copied from interface:Tuple2D
Set the y coordinate.- Specified by:
setY
in interfaceTuple2D<InnerComputationVector2afp>
- Parameters:
y
- value to y coordinate.
-
toUnmodifiable
public UnmodifiableVector2D<InnerComputationVector2afp,InnerComputationPoint2afp> toUnmodifiable()
Description copied from interface:Vector2D
Replies an unmodifiable copy of this vector.- Specified by:
toUnmodifiable
in interfaceVector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
- Returns:
- an unmodifiable copy.
-
toUnitVector
public InnerComputationVector2afp toUnitVector()
Description copied from interface:Vector2D
Replies the unit vector of this vector.- Specified by:
toUnitVector
in interfaceVector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
- Returns:
- the unit vector of this vector.
-
toOrthogonalVector
public InnerComputationVector2afp toOrthogonalVector()
Description copied from interface:Vector2D
Replies the orthogonal vector to this vector.The orthogonal vector is always the one obtain after a clockwise rotation of this vector.
The orthogonal vector does not depends on the current coordinate system.
- Specified by:
toOrthogonalVector
in interfaceVector2D<InnerComputationVector2afp,InnerComputationPoint2afp>
- Returns:
- the orthogonal vector.
-
-