Files
MapLibreParticleLab/platform/darwin/src/MLNSettings.h
mwilsnd 20d9e1028c Platform flattening overhaul (#1393)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Bart Louwers <bart@emeel.net>
2023-07-26 17:50:34 +02:00

63 lines
1.5 KiB
Objective-C
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#import <Foundation/Foundation.h>
#import "MLNFoundation.h"
#import "MLNTileServerOptions.h"
NS_ASSUME_NONNULL_BEGIN
/**
Well-known tile servers
*/
typedef NS_ENUM(NSUInteger, MLNWellKnownTileServer) {
/**
Maptiler
*/
MLNMapTiler,
/**
MapLibre
*/
MLNMapLibre,
/**
Mapbox
*/
MLNMapbox
};
/**
The `MLNSettings` object provides a global way to set SDK properties such
as apiKey, backend URL, etc.
*/
MLN_EXPORT
@interface MLNSettings : NSObject
// MARK: Tile Server Configuration
/**
Tile server options
*/
@property (class, copy, nullable) MLNTileServerOptions* tileServerOptions;
// MARK: Authorizing Access
/**
The API Key used by all instances of `MLNMapView` in the current application.
Setting this property to a value of `nil` has no effect.
@note You must set the API key before attempting to load any style which
requires the token. Therefore, you should generally set it before creating an instance of
`MLNMapView`. The recommended way to set an api key is to add an entry
to your application’s Info.plist file with the key `MLNApiKey`
and the type `String`. Alternatively, you may call this method from your
application delegate’s `-applicationDidFinishLaunching:` method.
*/
@property (class, copy, nullable) NSString *apiKey;
/**
Instructs the SDk to use the give tile server
*/
+ (void)useWellKnownTileServer:(MLNWellKnownTileServer)tileServer;
@end
NS_ASSUME_NONNULL_END