TencentMapSDK_iOS_3D_v6.7.0
QMapServices.h
1 //
2 // QMapServices.h
3 // QMapKit
4 //
5 // Copyright (c) 2017年 Tencent. All rights reserved.
6 //
7 
8 #import <Foundation/Foundation.h>
9 #import "QMapLoggerDefine.h"
10 
14 typedef NS_ENUM(NSInteger, QMapCacheClearType){
15  QMapCacheClearTypeCityData = 1
16 };
17 
21 @interface QMapCacheOption : NSObject
22 
26 @property (nonatomic, assign) QMapCacheClearType type;
27 
31 @property (nonatomic, assign) int sizeLimit;
32 
33 @end
34 
38 @interface QMapLoggerConfig : NSObject
39 
43 @property (nonatomic, assign) BOOL toFile;
44 
48 @property (nonatomic, assign) BOOL toConsole;
49 
53 @property (nonatomic, assign) QMapLogLevel level;
54 
59 @property (nonatomic, copy) NSArray* _Nullable tags;
60 
64 @property (nonatomic, assign) int32_t debugLogSizeLimit;
65 
69 @property (nonatomic, assign) int debugLogCacheDays;
70 
71 @end
72 
76 @interface QMapServices : NSObject
77 
81 + (nonnull QMapServices *)sharedServices;
82 
86 @property (nonnull, copy, nonatomic) NSString *APIKey;
87 
91 @property (nullable, nonatomic, copy) NSString *userId;
92 
96 @property (nullable, nonatomic, readonly) NSString *duid;
97 
101 - (NSString * _Nonnull)sdkVersion;
102 
108 - (void)setPrivacyAgreement:(BOOL)isAgree;
109 
110 
114 - (void)setQMapLoggerCofig:(QMapLoggerConfig* _Nullable) loggerConfig;
115 
121 @property (nonatomic) BOOL enableDebugLog DEPRECATED_ATTRIBUTE;
122 
128 - (void)ConfigMapCacheClearOption:(NSArray <QMapCacheOption *> * _Nullable)cacheOptions;
129 
135 - (int)getMapCacheClearSizeLimitByType:(QMapCacheClearType)type;
136 
137 @end
QMapLoggerConfig
回调日志格式类
Definition: QMapServices.h:39
QMapServices::duid
NSString * duid
获取 DUID标识值
Definition: QMapServices.h:96
QMapServices::APIKey
NSString * APIKey
apikey 在官网申请的服务授权标识的key
Definition: QMapServices.h:86
-[QMapServices sdkVersion]
NSString *_Nonnull sdkVersion()
获取地图SDK的版本号
QMapServices::userId
NSString * userId
自定义的用户ID,用于与开发者联调查询服务端日志的唯一标识
Definition: QMapServices.h:91
+[QMapServices sharedServices]
nonnull QMapServices * sharedServices()
获取单例
QMapServices
地图服务类
Definition: QMapServices.h:77
QMapCacheOption
缓存清理选项类
Definition: QMapServices.h:22
QMapCacheOption::type
QMapCacheClearType type
缓存清理类型,默认QMapCacheClearTypeCityData
Definition: QMapServices.h:26
QMapCacheOption::sizeLimit
int sizeLimit
缓存清理的阈值, 缓存大小大于此值时会对指定的缓存进行清理,单位:MB。[1, size],默认值:1。
Definition: QMapServices.h:31
QMapServices::DEPRECATED_ATTRIBUTE
BOOL enableDebugLog DEPRECATED_ATTRIBUTE
是否开启debug 日志. 默认为NO. @important: 正式发布版,切记不要开启.
Definition: QMapServices.h:121