Skip to content

Configuration File

Christoph edited this page Sep 9, 2022 · 4 revisions

The whole app will be set up with a JSON-based configuration file. The configuration controls not only the in-app purchases, map data and behaviour, but also (small) customisation. The following subpages of this chapter will be guide you through the configuration file. An example file is included in the repository.

The following wiki pages providing JSON examples for the different parts of the configuration. The footer offers a complete and empty configuration. Double and integer values, strings etc. in these examples are just placeholders and can be adjusted as needed. Mandatory configuration values are mentioned on the wiki pages.


graph TB;
    id1(Config)-->id2(mapThemes);
    id1(Config)-->id7(basemaps);
    id1(Config)-->id3(onStartup);
    id1(Config)-->id4(mapConstraints);
    id1(Config)-->id5(cacheName);
    id1(Config)-->id6(inAppPurchases);
Loading

Overview

The configuration file contains the following keys at the root level:

{
    "mapThemes": [],
    "basemaps": [],
    "onStartUp": {},
    "mapConstraints": {},
    "cacheName": "",
    "inAppPurchases": {}
}

Data

mapThemes

An array to configure all data sticked together to themes.

basemaps

An array containing basemaps available in the app.

onStartup

A dictionary containing different configurations directly after the app start.

mapConstraints

Different settings regarding the map behaviour.

cacheName

A string with the name of the internal directory for storing the cached map tiles. There are no restrictions for the cache name. The app is tested against the string TILE_CACHE.

inAppPurchases

Configurations regarding the in app purchases. Can be set to null to disable the in-app purchases, i.e. all map tools would be available.