com.vividsolutions.jts.algorithm
Class CentroidPoint
java.lang.Object
com.vividsolutions.jts.algorithm.CentroidPoint
public class CentroidPoint
extends java.lang.Object
Computes the centroid of a point geometry.
Algorithm
Compute the average of all points.
CentroidPoint
public CentroidPoint()
add
public void add(Coordinate pt)
Adds the length defined by an array of coordinates.
add
public void add(Geometry geom)
Adds the point(s) defined by a Geometry to the centroid total.
If the geometry is not of dimension 0 it does not contribute to the centroid.
geom
- the geometry to add