1
0
mirror of https://github.com/octoleo/plantuml.git synced 2024-06-02 16:40:49 +00:00
plantuml/src/zext/plantuml/com/ctreber/acearth/util/Polygon.java

50 lines
786 B
Java

package zext.plantuml.com.ctreber.acearth.util;
/**
* <p>A polygon in a 3 axis space.
*
* <p>&copy; 2002 Christian Treber, ct@ctreber.com
* @author Christian Treber, ct@ctreber.com
*
*/
public class Polygon
{
public static final int LAND = 1;
public static final int WATER = -1;
private int fType;
private Point3D[] fPoints;
public Polygon(int pType, Point3D[] pPoints)
{
fType = pType;
fPoints = pPoints;
}
public int getType()
{
return fType;
}
public Point3D[] getPoints()
{
return fPoints;
}
public Point3D getPoint(int pIndex)
{
return fPoints[pIndex];
}
public int getSize()
{
return fPoints.length;
}
public String toString()
{
return "Type " + fType + ", " + fPoints.length + " points";
}
}