Defines a connected set of line segments. Use to specify the color,
color mode, and width of the line. When a LineString is extruded, the line is extended
to the ground, forming a polygon that looks somewhat like a wall or fence. For extruded
LineStrings, the line itself uses the current LineStyle, and the extrusion uses
the current PolyStyle. See the KML Tutorial for examples of LineStrings (or paths).
Syntax:
<LineString id="ID">
<!-- specific to LineString -->
<extrude>0</extrude> <!-- boolean -->
<tessellate>0</tessellate> <!-- boolean -->
<altitudeMode>clampToGround</altitudeMode>
<!-- kml:altitudeModeEnum: clampToGround, relativeToGround, or absolute -->
<!-- or, substitute gx:altitudeMode: clampToSeaFloor, relativeToSeaFloor -->
<!-- or, substitute gx:altitudeMode: clampToSeaFloor, relativeToSeaFloor -->
<coordinates>... </coordinates> <!-- lon,lat[,alt] -->
</LineString>
Extends:
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
extrude
protected java.lang.Boolean extrude
Boolean value. Specifies whether to connect the LineString to the ground. To extrude
a LineString, the altitude mode must be either relativeToGround, relativeToSeaFloor,
or absolute. The vertices in the LineString are extruded toward the center of the
Earth's sphere.
Boolean value. Specifies whether to connect the LinearRing to the ground. To extrude
this geometry, the altitude mode must be either relativeToGround, relativeToSeaFloor,
or absolute. Only the vertices of the LinearRing are extruded, not the center of
the geometry. The vertices are extruded toward the center of the Earth's sphere.
Boolean value. Specifies whether to connect the Polygon to the ground. To extrude
a Polygon, the altitude mode must be either relativeToGround, relativeToSeaFloor,
or absolute. Only the vertices are extruded, not the geometry itself (for example,
a rectangle turns into a box with five faces. The vertices of the Polygon are extruded
toward the center of the Earth's sphere.
Boolean value. Specifies whether to connect the point to the ground with a line.
To extrude a Point, the value for must be either relativeToGround,
relativeToSeaFloor, or absolute. The point is extruded toward the center of the
Earth's sphere.
tessellate
protected java.lang.Boolean tessellate
Boolean value. Specifies whether to allow the LineString to follow the terrain.
To enable tessellation, the altitude mode must be clampToGround or clampToSeaFloor.
Very large LineStrings should enable tessellation so that they follow the curvature
of the earth (otherwise, they may go underground and be hidden).
Boolean value. Specifies whether to allow the LinearRing to follow the terrain.
To enable tessellation, the value for must be clampToGround or clampToSeaFloor.
Very large LinearRings should enable tessellation so that they follow the curvature
of the earth (otherwise, they may go underground and be hidden).
Boolean value. Specifies whether to allow the Polygon to follow the terrain. To
enable tessellation, the Polygon must have an altitude mode of clampToGround or
clampToSeaFloor. Very large Polygons should enable tessellation so that they follow
the curvature of the earth (otherwise, they may go underground and be hidden).
altitudeMode
protected AltitudeMode altitudeMode
AltitudeMode
clampToGround, relativeToGround, absolute
See Also:
See and
coordinates
protected java.util.List<Coordinate > coordinates
(required)
A single tuple consisting of floating point values for longitude, latitude, and
altitude (in that order). Longitude and latitude values are in degrees, where longitude
≥ −180 and <= 180 latitude ≥ −90 and ≤ 90 altitude values (optional) are in meters
above sea level
Do not include spaces between the three values that describe a coordinate.
Two or more coordinate tuples, each consisting of floating point values for longitude,
latitude, and altitude. The altitude component is optional. Insert a space between
tuples. Do not include spaces within a tuple.
lineStringSimpleExtension
protected java.util.List<java.lang.Object> lineStringSimpleExtension
lineStringObjectExtension
protected java.util.List<AbstractObject > lineStringObjectExtension
This is an abstract base class and cannot be used directly in a KML file. It provides
the id attribute, which allows unique identification of a KML element, and the targetId
attribute, which is used to reference objects that have already been loaded into
Google Earth. The id attribute must be assigned if the mechanism is to
be used.
Syntax:
<!-- abstract element; do not create -->
<!-- Object id="ID" targetId="NCName" -->
<!-- /Object > -->
LineString
public LineString ()
isExtrude
public java.lang.Boolean isExtrude ()
Returns: possible object is
Boolean
setExtrude
public void setExtrude (java.lang.Boolean value)
Parameters: value
- allowed object is
Boolean
See Also: extrude
isTessellate
public java.lang.Boolean isTessellate ()
Returns: possible object is
Boolean
setTessellate
public void setTessellate (java.lang.Boolean value)
Parameters: value
- allowed object is
Boolean
See Also: tessellate
getAltitudeMode
public AltitudeMode getAltitudeMode ()
Returns: possible object is
<
Object
<
AltitudeMode
<
de.micromata.opengis.kml.v_2_2_0.gx.AltitudeMode
See Also: altitudeMode
setAltitudeMode
public void setAltitudeMode (AltitudeMode value)
Parameters: value
- allowed object is
<
Object
<
AltitudeMode
<
de.micromata.opengis.kml.v_2_2_0.gx.AltitudeMode
See Also: altitudeMode
getLineStringSimpleExtension
public java.util.List<java.lang.Object> getLineStringSimpleExtension ()
See Also: lineStringSimpleExtension
getLineStringObjectExtension
public java.util.List<AbstractObject > getLineStringObjectExtension ()
See Also: lineStringObjectExtension
getCoordinates
public java.util.List<Coordinate > getCoordinates ()
See Also: coordinates
hashCode
public int hashCode ()
Overrides: hashCode
in class Geometry
equals
public boolean equals (java.lang.Object obj)
Overrides: equals
in class Geometry
setCoordinates
public void setCoordinates (java.util.List<Coordinate > coordinates)
Parameters: coordinates
- See Also: coordinates
addToCoordinates
public LineString addToCoordinates (double longitude,
double latitude)
add a value to the coordinates property collection
Parameters: longitude
- required parameterlatitude
- required parameter
Returns: true (as general contract of Collection.add ).
addToCoordinates
public LineString addToCoordinates (double longitude,
double latitude,
double altitude)
add a value to the coordinates property collection
Parameters: altitude
- required parameterlongitude
- required parameterlatitude
- required parameter
Returns: true (as general contract of Collection.add ).
addToCoordinates
public LineString addToCoordinates (java.lang.String coordinates)
add a value to the coordinates property collection
Parameters: coordinates
- required parameter
Returns: true (as general contract of Collection.add ).
setLineStringSimpleExtension
public void setLineStringSimpleExtension (java.util.List<java.lang.Object> lineStringSimpleExtension)
Parameters: lineStringSimpleExtension
- See Also: lineStringSimpleExtension
addToLineStringSimpleExtension
public LineString addToLineStringSimpleExtension (java.lang.Object lineStringSimpleExtension)
add a value to the lineStringSimpleExtension property collection
Parameters: lineStringSimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setLineStringObjectExtension
public void setLineStringObjectExtension (java.util.List<AbstractObject > lineStringObjectExtension)
Parameters: lineStringObjectExtension
- See Also: lineStringObjectExtension
addToLineStringObjectExtension
public LineString addToLineStringObjectExtension (AbstractObject lineStringObjectExtension)
add a value to the lineStringObjectExtension property collection
Parameters: lineStringObjectExtension
- Objects of the following type are allowed in the list: AbstractObject
Returns: true (as general contract of Collection.add ).
setObjectSimpleExtension
public void setObjectSimpleExtension (java.util.List<java.lang.Object> objectSimpleExtension)
Overrides: setObjectSimpleExtension
in class Geometry
See Also: objectSimpleExtension
addToObjectSimpleExtension
public LineString addToObjectSimpleExtension (java.lang.Object objectSimpleExtension)
Description copied from class: AbstractObject
add a value to the objectSimpleExtension property collection
Overrides: addToObjectSimpleExtension
in class Geometry
Parameters: objectSimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setGeometrySimpleExtension
public void setGeometrySimpleExtension (java.util.List<java.lang.Object> geometrySimpleExtension)
Overrides: setGeometrySimpleExtension
in class Geometry
See Also: geometrySimpleExtension
addToGeometrySimpleExtension
public LineString addToGeometrySimpleExtension (java.lang.Object geometrySimpleExtension)
Description copied from class: Geometry
add a value to the geometrySimpleExtension property collection
Overrides: addToGeometrySimpleExtension
in class Geometry
Parameters: geometrySimpleExtension
- Objects of the following type are allowed in the list: Object
Returns: true (as general contract of Collection.add ).
setGeometryObjectExtension
public void setGeometryObjectExtension (java.util.List<AbstractObject > geometryObjectExtension)
Overrides: setGeometryObjectExtension
in class Geometry
See Also: geometryObjectExtension
addToGeometryObjectExtension
public LineString addToGeometryObjectExtension (AbstractObject geometryObjectExtension)
Description copied from class: Geometry
add a value to the geometryObjectExtension property collection
Overrides: addToGeometryObjectExtension
in class Geometry
Parameters: geometryObjectExtension
- Objects of the following type are allowed in the list: AbstractObject
Returns: true (as general contract of Collection.add ).
withExtrude
public LineString withExtrude (java.lang.Boolean extrude)
fluent setter
Parameters: extrude
- required parameterSee Also: setExtrude(Boolean)
withTessellate
public LineString withTessellate (java.lang.Boolean tessellate)
fluent setter
Parameters: tessellate
- required parameterSee Also: setTessellate(Boolean)
withAltitudeMode
public LineString withAltitudeMode (AltitudeMode altitudeMode)
fluent setter
Parameters: altitudeMode
- required parameterSee Also: #setAltitudeMode(Object)
withCoordinates
public LineString withCoordinates (java.util.List<Coordinate > coordinates)
fluent setter
Parameters: coordinates
- required parameterSee Also: #setCoordinates(List)
withLineStringSimpleExtension
public LineString withLineStringSimpleExtension (java.util.List<java.lang.Object> lineStringSimpleExtension)
fluent setter
Parameters: lineStringSimpleExtension
- required parameterSee Also: #setLineStringSimpleExtension(List)
withLineStringObjectExtension
public LineString withLineStringObjectExtension (java.util.List<AbstractObject > lineStringObjectExtension)
fluent setter
Parameters: lineStringObjectExtension
- required parameterSee Also: #setLineStringObjectExtension(List)
withObjectSimpleExtension
public LineString withObjectSimpleExtension (java.util.List<java.lang.Object> objectSimpleExtension)
Description copied from class: AbstractObject
fluent setter
Overrides: withObjectSimpleExtension
in class Geometry
Parameters: objectSimpleExtension
- required parameterSee Also: #setObjectSimpleExtension(List)
withId
public LineString withId (java.lang.String id)
Description copied from class: AbstractObject
fluent setter
Overrides: withId
in class Geometry
Parameters: id
- required parameterSee Also: AbstractObject.setId(String)
withTargetId
public LineString withTargetId (java.lang.String targetId)
Description copied from class: AbstractObject
fluent setter
Overrides: withTargetId
in class Geometry
Parameters: targetId
- required parameterSee Also: AbstractObject.setTargetId(String)
withGeometrySimpleExtension
public LineString withGeometrySimpleExtension (java.util.List<java.lang.Object> geometrySimpleExtension)
Description copied from class: Geometry
fluent setter
Overrides: withGeometrySimpleExtension
in class Geometry
Parameters: geometrySimpleExtension
- required parameterSee Also: #setGeometrySimpleExtension(List)
withGeometryObjectExtension
public LineString withGeometryObjectExtension (java.util.List<AbstractObject > geometryObjectExtension)
Description copied from class: Geometry
fluent setter
Overrides: withGeometryObjectExtension
in class Geometry
Parameters: geometryObjectExtension
- required parameterSee Also: #setGeometryObjectExtension(List)
createAndSetCoordinates
public java.util.List<Coordinate > createAndSetCoordinates ()
Creates a new instance of List
<
Coordinate
and set it to this.coordinates.
This method is a short version for:
List newValue = new List();
this.setCoordinates(newValue);
clone
public LineString clone ()
Overrides: clone
in class Geometry