Package org.meteoinfo.jts.geom.util
Class LineStringExtracter
- java.lang.Object
-
- org.meteoinfo.jts.geom.util.LineStringExtracter
-
- All Implemented Interfaces:
GeometryFilter
public class LineStringExtracter extends java.lang.Object implements GeometryFilter
Extracts all theLineStringelements from aGeometry.- See Also:
GeometryExtracter
-
-
Constructor Summary
Constructors Constructor Description LineStringExtracter(java.util.List comps)Constructs a filter with a list in which to store the elements 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 GeometrygetGeometry(Geometry geom)Extracts theLineStringelements from a singleGeometryand returns them as either a {@link LineString) or {@link MultiLineString}.static java.util.ListgetLines(Geometry geom)static java.util.ListgetLines(Geometry geom, java.util.List lines)
-
-
-
Method Detail
-
getLines
public static java.util.List getLines(Geometry geom, java.util.List lines)
- Parameters:
geom- the geometry from which to extractlines- the list to add the extracted LineStrings to- Returns:
- the list argument
-
getLines
public static java.util.List getLines(Geometry geom)
- Parameters:
geom- the geometry from which to extract- Returns:
- a list containing the linear elements
-
getGeometry
public static Geometry getGeometry(Geometry geom)
Extracts theLineStringelements from a singleGeometryand returns them as either a {@link LineString) or {@link MultiLineString}.- Parameters:
geom- the geometry from which to extract- Returns:
- a linear geometry
-
filter
public void filter(Geometry geom)
Description copied from interface:GeometryFilterPerforms an operation with or ongeom.- Specified by:
filterin interfaceGeometryFilter- Parameters:
geom- aGeometryto which the filter is applied.
-
-