public class IntPolygon
extends java.lang.Object
| Constructor and Description |
|---|
IntPolygon()
Initialize a new instance of the IntPolygon class.
|
IntPolygon(int[] x,
int[] y)
Initialize a new instance of the IntPolygon class.
|
IntPolygon(int[] x,
int[] y,
int nPoints)
Initialize a new instance of the IntPolygon class.
|
IntPolygon(java.util.List<IntPoint> lstPoints)
Initialize a new instance of the IntPolygon class.
|
IntPolygon(java.util.List<IntPoint> lstPoints,
int nPoints)
Initialize a new instance of the IntPolygon class.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addPoint(int x,
int y)
Add point in the polygon.
|
void |
addPoint(IntPoint point)
Add point in the polygon.
|
int |
getNPoints()
Get number of points.
|
java.util.List<IntPoint> |
getPoints()
Get points.
|
int[] |
getX()
Get X axis coordinates.
|
int[] |
getY()
Get Y axis coordinates.
|
public IntPolygon()
public IntPolygon(int[] x,
int[] y)
x - X axis coordinate.y - Y axis coordinate.public IntPolygon(int[] x,
int[] y,
int nPoints)
x - X axis coordinate.y - Y axis coordinate.nPoints - Number of points.public IntPolygon(java.util.List<IntPoint> lstPoints)
lstPoints - List of points.public IntPolygon(java.util.List<IntPoint> lstPoints, int nPoints)
lstPoints - List of points.nPoints - Number of points.public int[] getX()
public int[] getY()
public int getNPoints()
public java.util.List<IntPoint> getPoints()
public void addPoint(IntPoint point)
point - Point.public void addPoint(int x,
int y)
x - X axis coordinate.y - Y axis coordinate.