remove Feature State
abstract fun removeFeatureState(sourceId: String, sourceLayerId: String? = null, featureId: String, stateKey: String? = null, callback: FeatureStateOperationCallback): Cancelable
Removes entries from a feature state object.
Remove a specified property or all property from a feature's state object, depending on the value of stateKey
.
Note that updates to feature state are asynchronous, so changes made by this method might not be immediately visible using getStateFeature
.
Return
A cancelable
object that could be used to cancel the pending operation.
Parameters
source Id
The style source identifier.
source Layer Id
The style source layer identifier (for multi-layer sources such as vector sources).
feature Id
The feature identifier of the feature whose state should be removed.
state Key
The key of the property to remove. If null
, all feature's state object properties are removed.
callback
The feature state operation callback
called when the operation completes or ends.