CustomLayer
constructor(id: String, uri: String, refreshToken: Int = 0, icons: Set<String> = emptySet(), groundOverlays: List<LayerGroundOverlay> = emptyList())(source)
Parameters
uri
a file://, https:// or data URI MapLibre can fetch GeoJSON from.
refreshToken
bumped by the host when the user asks to refresh this layer. A network layer keeps the same URI across a refresh, so without something that changes there is nothing to tell the map its contents moved on — see CustomLayers.
groundOverlays
images the layer drapes over the map (KML <GroundOverlay>), already resolved to local files with their corners computed.
icons
the distinct icon images the layer's features ask for, found by the host with geoJsonIconUrls. Supplied rather than discovered because MapLibre picks an icon per feature from a fixed set of style images, which has to exist before the layer composes.