com.vividsolutions.jts.algorithm

Class InteriorPointArea


public class InteriorPointArea
extends java.lang.Object

Computes a point in the interior of an area geometry.

Algorithm

Note: If a fixed precision model is used, in some cases this method may return a point which does not lie in the interior.
Version:
1.7

Constructor Summary

InteriorPointArea(Geometry g)

Method Summary

void
addPolygon(Geometry geometry)
Finds a reasonable point at which to label a Geometry.
Coordinate
centre(Envelope envelope)
Returns the centre point of the envelope.
Coordinate
getInteriorPoint()
protected LineString
horizontalBisector(Geometry geometry)
protected Geometry
widestGeometry(Geometry geometry)

Constructor Details

InteriorPointArea

public InteriorPointArea(Geometry g)

Method Details

addPolygon

public void addPolygon(Geometry geometry)
Finds a reasonable point at which to label a Geometry.
Parameters:
geometry - the geometry to analyze

centre

public Coordinate centre(Envelope envelope)
Returns the centre point of the envelope.
Parameters:
envelope - the envelope to analyze
Returns:
the centre of the envelope

getInteriorPoint

public Coordinate getInteriorPoint()

horizontalBisector

protected LineString horizontalBisector(Geometry geometry)

widestGeometry

protected Geometry widestGeometry(Geometry geometry)