new FeatureOverlay(manager, index)
Parameters:
Name | Type | Description |
---|---|---|
manager |
ngeo.FeatureOverlayMgr | The feature overlay manager. |
index |
number | This feature overlay's index. |
Methods
addFeature(feature)
Add a feature to the feature overlay.
Parameters:
Name | Type | Description |
---|---|---|
feature |
ol.Feature | The feature to add. |
clear()
Remove all the features from the feature overlay.
removeFeature(feature)
Remove a feature from the feature overlay.
Parameters:
Name | Type | Description |
---|---|---|
feature |
ol.Feature | The feature to remove. |
setFeatures(features)
Configure this feature overlay with a feature collection. Features added
to the collection are also added to the overlay. Same for removal. If you
configure the feature overlay with a feature collection you will use the
collection to add and remove features instead of using the overlay's
addFeature
, removeFeature
and clear
functions.
Parameters:
Name | Type | Description |
---|---|---|
features |
ol.Collection. |
Feature collection. |
setStyle(style)
Set a style for the feature overlay.
Parameters:
Name | Type | Description |
---|---|---|
style |
ol.style.Style|Array. |
Style. |