Package org.meteoinfo.jts.geom.util
Class ComponentCoordinateExtracter
- java.lang.Object
-
- org.meteoinfo.jts.geom.util.ComponentCoordinateExtracter
-
- All Implemented Interfaces:
GeometryComponentFilter
public class ComponentCoordinateExtracter extends java.lang.Object implements GeometryComponentFilter
Extracts a single representativeCoordinatefrom each connected component of aGeometry.
-
-
Constructor Summary
Constructors Constructor Description ComponentCoordinateExtracter(java.util.List coords)Constructs a LineExtracterFilter with a list in which to store LineStrings found.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidfilter(Geometry geom)Performs an operation with or ongeom.static java.util.ListgetCoordinates(Geometry geom)Extracts the linear components from a single geometry.
-
-
-
Method Detail
-
getCoordinates
public static java.util.List getCoordinates(Geometry geom)
Extracts the linear components from a single geometry. If more than one geometry is to be processed, it is more efficient to create a singleComponentCoordinateExtracterinstance and pass it to multiple geometries.- Parameters:
geom- the Geometry from which to extract- Returns:
- a list of Coordinates
-
filter
public void filter(Geometry geom)
Description copied from interface:GeometryComponentFilterPerforms an operation with or ongeom.- Specified by:
filterin interfaceGeometryComponentFilter- Parameters:
geom- aGeometryto which the filter is applied.
-
-