Package mil.nga.sf
Class MultiLineString
- java.lang.Object
-
- mil.nga.sf.Geometry
-
- mil.nga.sf.GeometryCollection<T>
-
- mil.nga.sf.MultiCurve<LineString>
-
- mil.nga.sf.MultiLineString
-
- All Implemented Interfaces:
Serializable
public class MultiLineString extends MultiCurve<LineString>
A restricted form of MultiCurve where each Curve in the collection must be of type LineString.- Author:
- osbornb
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MultiLineString()
ConstructorMultiLineString(boolean hasZ, boolean hasM)
ConstructorMultiLineString(List<LineString> lineStrings)
ConstructorMultiLineString(LineString lineString)
ConstructorMultiLineString(MultiLineString multiLineString)
Copy Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addLineString(LineString lineString)
Add a line stringvoid
addLineStrings(List<LineString> lineStrings)
Add line stringsGeometry
copy()
Copy the geometryLineString
getLineString(int n)
Returns the Nth line stringList<LineString>
getLineStrings()
Get the line stringsint
numLineStrings()
Get the number of line stringsvoid
setLineStrings(List<LineString> lineStrings)
Set the line strings-
Methods inherited from class mil.nga.sf.MultiCurve
addCurve, addCurves, getCurve, getCurves, isClosed, numCurves, setCurves
-
Methods inherited from class mil.nga.sf.GeometryCollection
addGeometries, addGeometry, equals, getAsGeometryCollection, getAsMultiCurve, getAsMultiLineString, getAsMultiPoint, getAsMultiPolygon, getAsMultiSurface, getCollectionType, getGeometries, getGeometry, hashCode, isEmpty, isMultiCurve, isMultiLineString, isMultiPoint, isMultiPolygon, isMultiSurface, isSimple, numGeometries, setGeometries
-
Methods inherited from class mil.nga.sf.Geometry
expandEnvelope, getCentroid, getDegreesCentroid, getDimension, getEnvelope, getGeometryType, hasM, hasZ, is3D, isMeasured, setHasM, setHasZ, updateZM
-
-
-
-
Constructor Detail
-
MultiLineString
public MultiLineString()
Constructor
-
MultiLineString
public MultiLineString(boolean hasZ, boolean hasM)
Constructor- Parameters:
hasZ
- has zhasM
- has m
-
MultiLineString
public MultiLineString(List<LineString> lineStrings)
Constructor- Parameters:
lineStrings
- list of line strings
-
MultiLineString
public MultiLineString(LineString lineString)
Constructor- Parameters:
lineString
- line string
-
MultiLineString
public MultiLineString(MultiLineString multiLineString)
Copy Constructor- Parameters:
multiLineString
- multi line string to copy
-
-
Method Detail
-
getLineStrings
public List<LineString> getLineStrings()
Get the line strings- Returns:
- line strings
-
setLineStrings
public void setLineStrings(List<LineString> lineStrings)
Set the line strings- Parameters:
lineStrings
- line strings
-
addLineString
public void addLineString(LineString lineString)
Add a line string- Parameters:
lineString
- line string
-
addLineStrings
public void addLineStrings(List<LineString> lineStrings)
Add line strings- Parameters:
lineStrings
- line strings
-
numLineStrings
public int numLineStrings()
Get the number of line strings- Returns:
- number of line strings
-
getLineString
public LineString getLineString(int n)
Returns the Nth line string- Parameters:
n
- nth line string to return- Returns:
- line string
-
copy
public Geometry copy()
Copy the geometry- Overrides:
copy
in classGeometryCollection<LineString>
- Returns:
- geometry copy
-
-