Package org.apache.pdfbox.util
Class Vector
- java.lang.Object
-
- org.apache.pdfbox.util.Vector
-
public final class Vector extends java.lang.ObjectA 2D vector.- Author:
- John Hewson
-
-
Constructor Summary
Constructors Constructor Description Vector(float x, float y)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description floatgetX()Returns the x magnitude.floatgetY()Returns the y magnitude.Vectorscale(float sxy)Returns a new vector scaled by both x and y.java.lang.StringtoString()
-
-
-
Method Detail
-
getX
public float getX()
Returns the x magnitude.
-
getY
public float getY()
Returns the y magnitude.
-
scale
public Vector scale(float sxy)
Returns a new vector scaled by both x and y.- Parameters:
sxy- x and y scale
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-