Package org.apache.pdfbox.util
Class Vector
java.lang.Object
org.apache.pdfbox.util.Vector
A 2D vector.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
x
private final float x -
y
private final float y
-
-
Constructor Details
-
Vector
public Vector(float x, float y)
-
-
Method Details
-
getX
public float getX()Returns the x magnitude.- Returns:
- the x magnitude
-
getY
public float getY()Returns the y magnitude.- Returns:
- the y magnitude
-
scale
Returns a new vector scaled by both x and y.- Parameters:
sxy- x and y scale- Returns:
- a new vector scaled by both x and y
-
toString
-