Skip to content

PresetsManager

Panoramax.utils.PresetsManager

Kind: static class of Panoramax.utils

new PresetsManager([lang], [skipLoad])

Presets Manager handle retrieval of presets against dedicated endpoint. It allows an easily search between all presets, and handles translations.

Param Type Default Description
[lang] string The user prefered language. Defaults to web browser preferences.
[skipLoad] boolean false Set to true to disable automatic load of API data

presetsManager.onceReady() ⇒ Promise

Resolves when the all necessary data was downloaded.

Kind: instance method of PresetsManager

presetsManager.getPreset() ⇒ Promise

Find the best matching preset for a given STAC feature.

Kind: instance method of PresetsManager
Fulfil: object|null The preset JSON that best matches, or null if no matches