Package com.massifmaps.vectorelements
Class Line
java.lang.Object
com.massifmaps.vectorelements.VectorElement
com.massifmaps.vectorelements.Line
A geometric line string that can be displayed on the map.
-
Constructor Summary
ConstructorsConstructorDescriptionLine(MapPosVector poses, LineStyle style) Constructs a Line object from a vector of map positions and a style.Line(LineGeometry geometry, LineStyle style) Constructs a Line object from a geometry object and a style. -
Method Summary
Modifier and TypeMethodDescriptionReturns the geometry object that defines the location of this vector element.getPoses()Returns the vertices that define this line.getStyle()Returns the style of this line.voidsetGeometry(LineGeometry geometry) Sets the location for this line.voidsetPoses(MapPosVector poses) Sets the vertices that define this line.voidSets the style for this line.Methods inherited from class com.massifmaps.vectorelements.VectorElement
containsMetaDataKey, equals, getBounds, getId, getMetaData, getMetaDataElement, hashCode, isVisible, notifyElementChanged, setId, setMetaData, setMetaDataElement, setVisible
-
Constructor Details
-
Line
Constructs a Line object from a geometry object and a style.- Parameters:
geometry- The geometry object that defines the location of this line.style- The style that defines what this line looks like.
-
Line
Constructs a Line object from a vector of map positions and a style.- Parameters:
poses- The vector of map positions that defines the location of this line.style- The style that defines what this line looks like.
-
-
Method Details
-
getGeometry
Description copied from class:VectorElementReturns the geometry object that defines the location of this vector element.- Overrides:
getGeometryin classVectorElement- Returns:
- The geometry object of this vector element.
-
setGeometry
Sets the location for this line.- Parameters:
geometry- The new geometry object that defines the location of this line.
-
getPoses
Returns the vertices that define this line.- Returns:
- The vector of map positions that defines this line.
-
setPoses
Sets the vertices that define this line.- Parameters:
poses- The new vector of map positions that defines this line.
-
getStyle
Returns the style of this line.- Returns:
- The style that defines what this line looks like.
-
setStyle
Sets the style for this line.- Parameters:
style- The new style that defines what this line looks like.
-