set Style Layer Properties Async
Experimental. Sets style layer properties asynchronously.
This method can be used to perform batch update for a style layer properties with asynchronous argument parsing which is beneficial when working with large or complex style expressions that could block the main thread during parsing. The operation is performed on a background thread and the callback is invoked on the main thread once the operation completes.
Properties will be applied asynchronously at some moment in the future. If multiple calls to this method are made, the corresponding properties will be applied in the same order as the calls were made.
Note: This method should be used only if the given arguments contain massive expressions and their parsing would block the main thread otherwise. For simple property values, prefer the synchronous setStyleLayerProperties method.
The structure of the provided properties value must conform to a format for a corresponding layer type. Modification of a layer id and/or a layer type is not allowed.
If the style is modified during this asynchronous method call, the scheduled layer properties change will still be applied as long as a layer with the original name and type still exists.
Return
A Cancelable object that can be used to cancel the asynchronous operation.
Parameters
A style layer identifier.
A map of style layer properties.
Called once the request is complete or an error occurred.