Package com.massifmaps.geometry
Class MultiLineGeometry
java.lang.Object
com.massifmaps.geometry.Geometry
com.massifmaps.geometry.MultiGeometry
com.massifmaps.geometry.MultiLineGeometry
A multiline container.
-
Constructor Summary
ConstructorsConstructorDescriptionMultiLineGeometry(LineGeometryVector geometries) Constructs a MultiLineGeometry object from the vector of lines. -
Method Summary
Modifier and TypeMethodDescriptiongetGeometry(int index) Returns the line geometry at the specified index.intgetType()Returns what kind of geometry this is.
Without it the only way to tell a MultiPoint from a Point is a downcast, or - from a
scripting binding - matching on the wrapper's class name.Methods inherited from class com.massifmaps.geometry.MultiGeometry
getCenterPos, getGeometryCountMethods inherited from class com.massifmaps.geometry.Geometry
equals, getBounds, getGeoJSON, hashCode
-
Constructor Details
-
MultiLineGeometry
Constructs a MultiLineGeometry object from the vector of lines.- Parameters:
geometries- The vector of line geometries.
-
-
Method Details
-
getType
public int getType()Description copied from class:GeometryReturns what kind of geometry this is.
Without it the only way to tell a MultiPoint from a Point is a downcast, or - from a
scripting binding - matching on the wrapper's class name.- Overrides:
getTypein classMultiGeometry- Returns:
- The geometry type.
-
getGeometry
Returns the line geometry at the specified index. Index must be between 0 and getGeometryCount (exclusive)- Overrides:
getGeometryin classMultiGeometry- Parameters:
index- The index of the line geometry.- Returns:
- The line geometry at specified index.
- Throws:
IndexOutOfBoundsException- If the index is out of range.
-