net.sf.geographiclib.PolygonResult Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of GeographicLib-Java Show documentation
Show all versions of GeographicLib-Java Show documentation
This is a Java implementation of the geodesic algorithms from
GeographicLib. This is a self-contained library to solve geodesic
problems on an ellipsoid model of the earth. It requires Java
version 1.7 or later.
/**
* Implementation of the net.sf.geographiclib.PolygonResult class
*
* Copyright (c) Charles Karney (2013) and licensed
* under the MIT/X11 License. For more information, see
* https://geographiclib.sourceforge.io/
**********************************************************************/
package net.sf.geographiclib;
/**
* A container for the results from PolygonArea.
**********************************************************************/
public class PolygonResult {
/**
* The number of vertices in the polygon
**********************************************************************/
public int num;
/**
* The perimeter of the polygon or the length of the polyline (meters).
**********************************************************************/
public double perimeter;
/**
* The area of the polygon (meters2).
**********************************************************************/
public double area;
/**
* Constructor
*
* @param num the number of vertices in the polygon.
* @param perimeter the perimeter of the polygon or the length of the
* polyline (meters).
* @param area the area of the polygon (meters2).
**********************************************************************/
public PolygonResult(int num, double perimeter, double area) {
this.num = num;
this.perimeter = perimeter;
this.area = area;
}
}