new cercalia.KML(options)
Name | Type | Description | |||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Hash table with extra options to configure the KML layer
|
Extends
Methods
-
addFeature(feature)
src/cercalia/kml.js, line 359 -
Name Type Description feature
cercalia.Feature | cercalia.Marker | ol.Feature feature.
-
addFeaturesFromKML(kml, proj)
src/cercalia/kml.js, line 378 -
Name Type Description kml
string KML as string.
proj
string Data projection.
-
centerToFeatures()
src/cercalia/kml.js, line 476 -
Center to loaded features
-
clear()
src/cercalia/kml.js, line 458 -
Clear all features
-
Returns:
Get Class name of object
-
getFeatures(){Array}
src/cercalia/kml.js, line 342 -
Returns:
Array of KML features.
-
Returns:
Unique Id.
-
getKML(){string}
src/cercalia/kml.js, line 421 -
Returns:
Kml of features in layer.
-
Get Layer of KML features.
Returns:
Layer vector
-
return cercalia map
Returns:
map
-
getMaxResolution(){number|undefined}
src/cercalia/kml.js, line 246 -
Returns:
maxResolution
-
getMinResolution(){number|undefined}
src/cercalia/kml.js, line 228 -
Returns:
minResolution
-
getOpacity(){number}
src/cercalia/kml.js, line 263 -
Returns:
opacity
-
getProjection(){string}
src/cercalia/kml.js, line 307 -
Returns:
Projection.
-
getUrl(){string}
src/cercalia/kml.js, line 271 -
Returns:
url
-
getVisible(){boolean}
src/cercalia/kml.js, line 290 -
Get if map is visible
Returns:
true
if layer is visible.
-
isDraggable(){boolean}
src/cercalia/kml.js, line 334 -
Returns:
Returns if KML features are draggable.
-
removeFeature(feature)
src/cercalia/kml.js, line 408 -
Remove a single feature from the source. If you want to remove all features at once, use the
clear()
method insteadName Type Description feature
cercalia.Feature | cercalia.Marker | ol.Feature Feature to remove.
-
setDraggable(draggable)
src/cercalia/kml.js, line 316 -
Converts features to draggable.
Name Type Description draggable
boolean Draggable
true
orfalse
. -
setMaxResolution(maxResolution)
src/cercalia/kml.js, line 237 -
Name Type Description maxResolution
number Maximum resolution.
-
setMinResolution(minResolution)
src/cercalia/kml.js, line 219 -
Name Type Description minResolution
number Minimum resolution
-
setOpacity(opacity)
src/cercalia/kml.js, line 254 -
Name Type Description opacity
number Opacity. Decimal value in `0..1' .
-
setUrl(url)
src/cercalia/kml.js, line 467 -
Name Type Description url
string Url
-
setVisible(visible)
src/cercalia/kml.js, line 280 -
Show KML in mapa.
Name Type Description visible
boolean Set the visibility of the layer (
true
orfalse
)