getInstance

Get an instance of MapLibre.

This class manages the API key, application context, and connectivity state.

Return

the single instance of MapLibre

Parameters

context

Android context which holds or is an application context


open fun getInstance(@NonNull context: Context, @Nullable apiKey: String, tileServer: WellKnownTileServer): MapLibre

Get an instance of MapLibre.

This class manages the API key, application context, and connectivity state.

Return

the single instance of MapLibre

Parameters

context

Android context which holds or is an application context

apiKey

api key

tileServer

the tile server whose predefined configuration will be used to bootstrap the SDK. The predefined configuration includes rules for converting resource URLs between normal and canonical forms and set of predefined styles available on the server.