Class PointI
java.lang.Object
com.compdfkit.core.android.graphics.PointI
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanequals(int x, int y) Returns true if the point's coordinates equal (x,y)booleaninthashCode()final floatlength()Return the euclidian distance from (0,0) to the pointstatic floatlength(int x, int y) Returns the euclidian distance from (0,0) to (x,y)final voidnegate()final voidoffset(float dx, float dy) final voidset(int x, int y) Set the point's x and y coordinatesfinal voidSet the point's x and y coordinates to the coordinates of ptoString()
-
Field Details
-
x
public int x -
y
public int y
-
-
Constructor Details
-
PointI
public PointI() -
PointI
public PointI(int x, int y) -
PointI
Create a new PointI initialized with the values in the specified PointI (which is left unmodified).- Parameters:
p- The point whose values are copied into the new point.
-
-
Method Details
-
set
public final void set(int x, int y) Set the point's x and y coordinates -
set
Set the point's x and y coordinates to the coordinates of p -
negate
public final void negate() -
offset
public final void offset(float dx, float dy) -
equals
public final boolean equals(int x, int y) Returns true if the point's coordinates equal (x,y) -
equals
-
hashCode
public int hashCode() -
toString
-
length
public final float length()Return the euclidian distance from (0,0) to the point -
length
public static float length(int x, int y) Returns the euclidian distance from (0,0) to (x,y)
-