MapboxNavigation-Swift.h 92 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608
  1. // Generated by Apple Swift version 5.5.2 (swiftlang-1300.0.47.5 clang-1300.0.29.30)
  2. #ifndef MAPBOXNAVIGATION_SWIFT_H
  3. #define MAPBOXNAVIGATION_SWIFT_H
  4. #pragma clang diagnostic push
  5. #pragma clang diagnostic ignored "-Wgcc-compat"
  6. #if !defined(__has_include)
  7. # define __has_include(x) 0
  8. #endif
  9. #if !defined(__has_attribute)
  10. # define __has_attribute(x) 0
  11. #endif
  12. #if !defined(__has_feature)
  13. # define __has_feature(x) 0
  14. #endif
  15. #if !defined(__has_warning)
  16. # define __has_warning(x) 0
  17. #endif
  18. #if __has_include(<swift/objc-prologue.h>)
  19. # include <swift/objc-prologue.h>
  20. #endif
  21. #pragma clang diagnostic ignored "-Wauto-import"
  22. #include <Foundation/Foundation.h>
  23. #include <stdint.h>
  24. #include <stddef.h>
  25. #include <stdbool.h>
  26. #if !defined(SWIFT_TYPEDEFS)
  27. # define SWIFT_TYPEDEFS 1
  28. # if __has_include(<uchar.h>)
  29. # include <uchar.h>
  30. # elif !defined(__cplusplus)
  31. typedef uint_least16_t char16_t;
  32. typedef uint_least32_t char32_t;
  33. # endif
  34. typedef float swift_float2 __attribute__((__ext_vector_type__(2)));
  35. typedef float swift_float3 __attribute__((__ext_vector_type__(3)));
  36. typedef float swift_float4 __attribute__((__ext_vector_type__(4)));
  37. typedef double swift_double2 __attribute__((__ext_vector_type__(2)));
  38. typedef double swift_double3 __attribute__((__ext_vector_type__(3)));
  39. typedef double swift_double4 __attribute__((__ext_vector_type__(4)));
  40. typedef int swift_int2 __attribute__((__ext_vector_type__(2)));
  41. typedef int swift_int3 __attribute__((__ext_vector_type__(3)));
  42. typedef int swift_int4 __attribute__((__ext_vector_type__(4)));
  43. typedef unsigned int swift_uint2 __attribute__((__ext_vector_type__(2)));
  44. typedef unsigned int swift_uint3 __attribute__((__ext_vector_type__(3)));
  45. typedef unsigned int swift_uint4 __attribute__((__ext_vector_type__(4)));
  46. #endif
  47. #if !defined(SWIFT_PASTE)
  48. # define SWIFT_PASTE_HELPER(x, y) x##y
  49. # define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y)
  50. #endif
  51. #if !defined(SWIFT_METATYPE)
  52. # define SWIFT_METATYPE(X) Class
  53. #endif
  54. #if !defined(SWIFT_CLASS_PROPERTY)
  55. # if __has_feature(objc_class_property)
  56. # define SWIFT_CLASS_PROPERTY(...) __VA_ARGS__
  57. # else
  58. # define SWIFT_CLASS_PROPERTY(...)
  59. # endif
  60. #endif
  61. #if __has_attribute(objc_runtime_name)
  62. # define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X)))
  63. #else
  64. # define SWIFT_RUNTIME_NAME(X)
  65. #endif
  66. #if __has_attribute(swift_name)
  67. # define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X)))
  68. #else
  69. # define SWIFT_COMPILE_NAME(X)
  70. #endif
  71. #if __has_attribute(objc_method_family)
  72. # define SWIFT_METHOD_FAMILY(X) __attribute__((objc_method_family(X)))
  73. #else
  74. # define SWIFT_METHOD_FAMILY(X)
  75. #endif
  76. #if __has_attribute(noescape)
  77. # define SWIFT_NOESCAPE __attribute__((noescape))
  78. #else
  79. # define SWIFT_NOESCAPE
  80. #endif
  81. #if __has_attribute(ns_consumed)
  82. # define SWIFT_RELEASES_ARGUMENT __attribute__((ns_consumed))
  83. #else
  84. # define SWIFT_RELEASES_ARGUMENT
  85. #endif
  86. #if __has_attribute(warn_unused_result)
  87. # define SWIFT_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
  88. #else
  89. # define SWIFT_WARN_UNUSED_RESULT
  90. #endif
  91. #if __has_attribute(noreturn)
  92. # define SWIFT_NORETURN __attribute__((noreturn))
  93. #else
  94. # define SWIFT_NORETURN
  95. #endif
  96. #if !defined(SWIFT_CLASS_EXTRA)
  97. # define SWIFT_CLASS_EXTRA
  98. #endif
  99. #if !defined(SWIFT_PROTOCOL_EXTRA)
  100. # define SWIFT_PROTOCOL_EXTRA
  101. #endif
  102. #if !defined(SWIFT_ENUM_EXTRA)
  103. # define SWIFT_ENUM_EXTRA
  104. #endif
  105. #if !defined(SWIFT_CLASS)
  106. # if __has_attribute(objc_subclassing_restricted)
  107. # define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA
  108. # define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
  109. # else
  110. # define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
  111. # define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA
  112. # endif
  113. #endif
  114. #if !defined(SWIFT_RESILIENT_CLASS)
  115. # if __has_attribute(objc_class_stub)
  116. # define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME) __attribute__((objc_class_stub))
  117. # define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_class_stub)) SWIFT_CLASS_NAMED(SWIFT_NAME)
  118. # else
  119. # define SWIFT_RESILIENT_CLASS(SWIFT_NAME) SWIFT_CLASS(SWIFT_NAME)
  120. # define SWIFT_RESILIENT_CLASS_NAMED(SWIFT_NAME) SWIFT_CLASS_NAMED(SWIFT_NAME)
  121. # endif
  122. #endif
  123. #if !defined(SWIFT_PROTOCOL)
  124. # define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
  125. # define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA
  126. #endif
  127. #if !defined(SWIFT_EXTENSION)
  128. # define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__)
  129. #endif
  130. #if !defined(OBJC_DESIGNATED_INITIALIZER)
  131. # if __has_attribute(objc_designated_initializer)
  132. # define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer))
  133. # else
  134. # define OBJC_DESIGNATED_INITIALIZER
  135. # endif
  136. #endif
  137. #if !defined(SWIFT_ENUM_ATTR)
  138. # if defined(__has_attribute) && __has_attribute(enum_extensibility)
  139. # define SWIFT_ENUM_ATTR(_extensibility) __attribute__((enum_extensibility(_extensibility)))
  140. # else
  141. # define SWIFT_ENUM_ATTR(_extensibility)
  142. # endif
  143. #endif
  144. #if !defined(SWIFT_ENUM)
  145. # define SWIFT_ENUM(_type, _name, _extensibility) enum _name : _type _name; enum SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
  146. # if __has_feature(generalized_swift_name)
  147. # define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) enum _name : _type _name SWIFT_COMPILE_NAME(SWIFT_NAME); enum SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_ENUM_ATTR(_extensibility) SWIFT_ENUM_EXTRA _name : _type
  148. # else
  149. # define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME, _extensibility) SWIFT_ENUM(_type, _name, _extensibility)
  150. # endif
  151. #endif
  152. #if !defined(SWIFT_UNAVAILABLE)
  153. # define SWIFT_UNAVAILABLE __attribute__((unavailable))
  154. #endif
  155. #if !defined(SWIFT_UNAVAILABLE_MSG)
  156. # define SWIFT_UNAVAILABLE_MSG(msg) __attribute__((unavailable(msg)))
  157. #endif
  158. #if !defined(SWIFT_AVAILABILITY)
  159. # define SWIFT_AVAILABILITY(plat, ...) __attribute__((availability(plat, __VA_ARGS__)))
  160. #endif
  161. #if !defined(SWIFT_WEAK_IMPORT)
  162. # define SWIFT_WEAK_IMPORT __attribute__((weak_import))
  163. #endif
  164. #if !defined(SWIFT_DEPRECATED)
  165. # define SWIFT_DEPRECATED __attribute__((deprecated))
  166. #endif
  167. #if !defined(SWIFT_DEPRECATED_MSG)
  168. # define SWIFT_DEPRECATED_MSG(...) __attribute__((deprecated(__VA_ARGS__)))
  169. #endif
  170. #if __has_feature(attribute_diagnose_if_objc)
  171. # define SWIFT_DEPRECATED_OBJC(Msg) __attribute__((diagnose_if(1, Msg, "warning")))
  172. #else
  173. # define SWIFT_DEPRECATED_OBJC(Msg) SWIFT_DEPRECATED_MSG(Msg)
  174. #endif
  175. #if !defined(IBSegueAction)
  176. # define IBSegueAction
  177. #endif
  178. #if __has_feature(modules)
  179. #if __has_warning("-Watimport-in-framework-header")
  180. #pragma clang diagnostic ignored "-Watimport-in-framework-header"
  181. #endif
  182. @import AVFAudio;
  183. @import CarPlay;
  184. @import CoreGraphics;
  185. @import CoreLocation;
  186. @import Foundation;
  187. @import ObjectiveC;
  188. @import UIKit;
  189. #endif
  190. #pragma clang diagnostic ignored "-Wproperty-attribute-mismatch"
  191. #pragma clang diagnostic ignored "-Wduplicate-method-arg"
  192. #if __has_warning("-Wpragma-clang-attribute")
  193. # pragma clang diagnostic ignored "-Wpragma-clang-attribute"
  194. #endif
  195. #pragma clang diagnostic ignored "-Wunknown-pragmas"
  196. #pragma clang diagnostic ignored "-Wnullability"
  197. #if __has_attribute(external_source_symbol)
  198. # pragma push_macro("any")
  199. # undef any
  200. # pragma clang attribute push(__attribute__((external_source_symbol(language="Swift", defined_in="MapboxNavigation",generated_declaration))), apply_to=any(function,enum,objc_interface,objc_category,objc_protocol))
  201. # pragma pop_macro("any")
  202. #endif
  203. @class UIColor;
  204. @class UIFont;
  205. @class NSNumber;
  206. @class NSCoder;
  207. SWIFT_CLASS_NAMED("StylableLabel")
  208. @interface MBStylableLabel : UILabel
  209. @property (nonatomic, strong) UIColor * _Nonnull normalTextColor;
  210. @property (nonatomic, strong) UIFont * _Nonnull normalFont;
  211. @property (nonatomic, strong) UIColor * _Nonnull textColorHighlighted;
  212. @property (nonatomic) BOOL showHighlightedTextColor;
  213. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  214. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  215. @end
  216. SWIFT_CLASS_NAMED("ArrivalTimeLabel")
  217. @interface MBArrivalTimeLabel : MBStylableLabel
  218. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  219. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  220. @end
  221. SWIFT_CLASS_NAMED("BannerContainerView")
  222. @interface MBBannerContainerView : UIView
  223. - (void)safeAreaInsetsDidChange;
  224. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  225. - (void)didMoveToSuperview;
  226. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  227. @end
  228. @class UITraitCollection;
  229. /// A banner view that contains the current step instruction along a route and responds to tap and
  230. /// swipe gestures, as the base of <code>InstructionsCardView</code> and <code>InstructionsBannerView</code>.
  231. SWIFT_CLASS("_TtC16MapboxNavigation26BaseInstructionsBannerView")
  232. @interface BaseInstructionsBannerView : UIControl
  233. /// A <code>Boolean</code> value controls whether the banner view reponds to swipe gestures. Defaults to <code>false</code>.
  234. @property (nonatomic) IBInspectable BOOL swipeable;
  235. /// A <code>Boolean</code> value controls whether the banner view shows the <code>StepListIndicatorView</code>. Defaults to <code>true</code>.
  236. @property (nonatomic) IBInspectable BOOL showStepIndicator;
  237. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  238. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  239. - (void)prepareForInterfaceBuilder;
  240. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  241. @end
  242. /// A cache consists of both in-memory and on-disk components, both of which can be reset.
  243. SWIFT_PROTOCOL_NAMED("BimodalCache")
  244. @protocol MBBimodalCache
  245. - (void)clearMemory;
  246. - (void)clearDiskWithCompletion:(void (^ _Nullable)(void))completion;
  247. @end
  248. SWIFT_CLASS_NAMED("BottomBannerView")
  249. @interface MBBottomBannerView : UIView
  250. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  251. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  252. @end
  253. @class NSString;
  254. @class NSBundle;
  255. /// A user interface element designed to display the estimated arrival time, distance, and time remaining, as well as give the user a control the cancel the navigation session.
  256. IB_DESIGNABLE
  257. SWIFT_CLASS("_TtC16MapboxNavigation26BottomBannerViewController")
  258. @interface BottomBannerViewController : UIViewController
  259. /// Initializes a <code>BottomBannerViewController</code> that provides ETA, Distance to arrival, and Time to arrival.
  260. /// \param nibNameOrNil Ignored.
  261. ///
  262. /// \param nibBundleOrNil Ignored.
  263. ///
  264. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil OBJC_DESIGNATED_INITIALIZER;
  265. /// Initializes a <code>BottomBannerViewController</code> that provides ETA, Distance to arrival, and Time to arrival.
  266. /// \param aDecoder Ignored.
  267. ///
  268. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  269. - (void)viewWillDisappear:(BOOL)animated;
  270. - (void)viewDidLoad;
  271. - (void)prepareForInterfaceBuilder;
  272. @end
  273. @interface BottomBannerViewController (SWIFT_EXTENSION(MapboxNavigation))
  274. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  275. @end
  276. SWIFT_CLASS("_TtC16MapboxNavigation17BottomPaddingView")
  277. @interface BottomPaddingView : MBBottomBannerView
  278. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  279. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  280. @end
  281. SWIFT_CLASS_NAMED("StylableButton")
  282. @interface MBStylableButton : UIButton
  283. @property (nonatomic, strong) UIFont * _Nonnull textFont;
  284. @property (nonatomic, strong) UIColor * _Nonnull textColor;
  285. @property (nonatomic, strong) UIColor * _Nonnull borderColor;
  286. @property (nonatomic) CGFloat borderWidth;
  287. @property (nonatomic) CGFloat cornerRadius;
  288. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  289. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  290. @end
  291. /// :nodoc:
  292. /// <code>Button</code> sets the tintColor according to the style.
  293. SWIFT_CLASS_NAMED("Button")
  294. @interface MBButton : MBStylableButton
  295. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  296. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  297. @end
  298. SWIFT_CLASS_NAMED("CancelButton")
  299. @interface MBCancelButton : MBButton
  300. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  301. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  302. @end
  303. SWIFT_CLASS_NAMED("StylableView")
  304. @interface MBStylableView : UIView
  305. @property (nonatomic) CGFloat borderWidth;
  306. @property (nonatomic) CGFloat cornerRadius;
  307. @property (nonatomic, strong) UIColor * _Nullable borderColor;
  308. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  309. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  310. @end
  311. /// A control indicating the direction that the vehicle is traveling towards.
  312. SWIFT_CLASS("_TtC16MapboxNavigation18CarPlayCompassView")
  313. @interface CarPlayCompassView : MBStylableView
  314. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  315. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  316. @end
  317. /// <code>CarPlayManager</code> is the main object responsible for orchestrating interactions with a Mapbox map on CarPlay.
  318. /// Messages declared in the <code>CPApplicationDelegate</code> protocol should be sent to this object in the containing application’s application delegate. Implement <code>CarPlayManagerDelegate</code> in the containing application and assign an instance to the <code>delegate</code> property of your <code>CarPlayManager</code> instance.
  319. /// note:
  320. /// It is very important you have a single <code>CarPlayManager</code> instance at any given time. This should be managed by your <code>UIApplicationDelegate</code> class if you choose to supply your <code>accessToken</code> to the <code>CarPlayManager.eventsManager</code> via <code>NavigationEventsManager</code> initializer, instead of the Info.plist.
  321. SWIFT_CLASS("_TtC16MapboxNavigation14CarPlayManager") SWIFT_AVAILABILITY(ios,introduced=12.0)
  322. @interface CarPlayManager : NSObject
  323. - (nonnull instancetype)init SWIFT_UNAVAILABLE;
  324. + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
  325. @end
  326. @class CPTemplate;
  327. SWIFT_AVAILABILITY(ios,introduced=12.0)
  328. @interface CarPlayManager (SWIFT_EXTENSION(MapboxNavigation)) <CPInterfaceControllerDelegate>
  329. - (void)templateWillAppear:(CPTemplate * _Nonnull)template_ animated:(BOOL)animated;
  330. - (void)templateDidAppear:(CPTemplate * _Nonnull)template_ animated:(BOOL)animated;
  331. - (void)templateWillDisappear:(CPTemplate * _Nonnull)template_ animated:(BOOL)animated;
  332. - (void)templateDidDisappear:(CPTemplate * _Nonnull)template_ animated:(BOOL)animated;
  333. @end
  334. @class UIApplication;
  335. @class CPInterfaceController;
  336. @class CPWindow;
  337. SWIFT_AVAILABILITY(ios,introduced=12.0)
  338. @interface CarPlayManager (SWIFT_EXTENSION(MapboxNavigation)) <CPApplicationDelegate>
  339. - (void)application:(UIApplication * _Nonnull)application didConnectCarInterfaceController:(CPInterfaceController * _Nonnull)interfaceController toWindow:(CPWindow * _Nonnull)window;
  340. - (void)application:(UIApplication * _Nonnull)application didDisconnectCarInterfaceController:(CPInterfaceController * _Nonnull)interfaceController fromWindow:(CPWindow * _Nonnull)window;
  341. @end
  342. @class CPMapTemplate;
  343. @class CPTrip;
  344. @class CPRouteChoice;
  345. @class CPManeuver;
  346. @class CPNavigationAlert;
  347. @class CPTravelEstimates;
  348. SWIFT_AVAILABILITY(ios,introduced=12.0)
  349. @interface CarPlayManager (SWIFT_EXTENSION(MapboxNavigation)) <CPMapTemplateDelegate>
  350. - (void)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate startedTrip:(CPTrip * _Nonnull)trip usingRouteChoice:(CPRouteChoice * _Nonnull)routeChoice;
  351. - (void)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate selectedPreviewForTrip:(CPTrip * _Nonnull)trip usingRouteChoice:(CPRouteChoice * _Nonnull)routeChoice;
  352. - (void)mapTemplateDidCancelNavigation:(CPMapTemplate * _Nonnull)mapTemplate;
  353. - (void)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate didEndPanGestureWithVelocity:(CGPoint)velocity;
  354. - (void)mapTemplateDidShowPanningInterface:(CPMapTemplate * _Nonnull)mapTemplate;
  355. - (void)mapTemplateWillDismissPanningInterface:(CPMapTemplate * _Nonnull)mapTemplate;
  356. - (void)mapTemplateDidDismissPanningInterface:(CPMapTemplate * _Nonnull)mapTemplate;
  357. - (void)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate didUpdatePanGestureWithTranslation:(CGPoint)translation velocity:(CGPoint)velocity;
  358. - (void)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate panWithDirection:(CPPanDirection)direction;
  359. - (CPManeuverDisplayStyle)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate displayStyleForManeuver:(CPManeuver * _Nonnull)maneuver SWIFT_WARN_UNUSED_RESULT;
  360. - (BOOL)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate shouldShowNotificationForManeuver:(CPManeuver * _Nonnull)maneuver SWIFT_WARN_UNUSED_RESULT;
  361. - (BOOL)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate shouldShowNotificationForNavigationAlert:(CPNavigationAlert * _Nonnull)navigationAlert SWIFT_WARN_UNUSED_RESULT;
  362. - (BOOL)mapTemplate:(CPMapTemplate * _Nonnull)mapTemplate shouldUpdateNotificationForManeuver:(CPManeuver * _Nonnull)maneuver withTravelEstimates:(CPTravelEstimates * _Nonnull)travelEstimates SWIFT_WARN_UNUSED_RESULT;
  363. @end
  364. /// <code>CarPlayMapViewController</code> is responsible for administering the Mapbox map, the interface styles and the map template buttons to display on CarPlay.
  365. SWIFT_CLASS("_TtC16MapboxNavigation24CarPlayMapViewController") SWIFT_AVAILABILITY(ios,introduced=12.0)
  366. @interface CarPlayMapViewController : UIViewController
  367. /// Returns a <code>CarPlayMapViewController</code> object initialized from data in a given unarchiver.
  368. /// \param coder An unarchiver object.
  369. ///
  370. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  371. - (void)encodeWithCoder:(NSCoder * _Nonnull)aCoder;
  372. - (void)loadView;
  373. - (void)viewDidLoad;
  374. - (void)viewWillAppear:(BOOL)animated;
  375. - (void)viewSafeAreaInsetsDidChange;
  376. - (void)updateViewConstraints;
  377. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
  378. @end
  379. @class CPSessionConfiguration;
  380. SWIFT_AVAILABILITY(ios,introduced=12.0)
  381. @interface CarPlayMapViewController (SWIFT_EXTENSION(MapboxNavigation)) <CPSessionConfigurationDelegate>
  382. - (void)sessionConfiguration:(CPSessionConfiguration * _Nonnull)sessionConfiguration contentStyleChanged:(CPContentStyle)contentStyle SWIFT_AVAILABILITY(ios,introduced=13.0);
  383. @end
  384. /// <code>CarPlayNavigationViewController</code> is a fully-featured turn-by-turn navigation UI for CarPlay.
  385. /// seealso:
  386. /// <code>NavigationViewController</code>
  387. SWIFT_CLASS("_TtC16MapboxNavigation31CarPlayNavigationViewController") SWIFT_AVAILABILITY(ios,introduced=12.0)
  388. @interface CarPlayNavigationViewController : UIViewController
  389. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  390. - (void)viewDidLoad;
  391. - (void)viewWillAppear:(BOOL)animated;
  392. - (void)viewWillDisappear:(BOOL)animated;
  393. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  394. - (void)viewSafeAreaInsetsDidChange;
  395. - (void)updateViewConstraints;
  396. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
  397. @end
  398. @class CPListTemplate;
  399. @class CPListItem;
  400. SWIFT_AVAILABILITY(ios,introduced=12.0)
  401. @interface CarPlayNavigationViewController (SWIFT_EXTENSION(MapboxNavigation)) <CPListTemplateDelegate>
  402. - (void)listTemplate:(CPListTemplate * _Nonnull)listTemplate didSelectListItem:(CPListItem * _Nonnull)item completionHandler:(void (^ _Nonnull)(void))completionHandler;
  403. @end
  404. SWIFT_AVAILABILITY(ios,introduced=12.0)
  405. @interface CarPlayNavigationViewController (SWIFT_EXTENSION(MapboxNavigation)) <CPSessionConfigurationDelegate>
  406. - (void)sessionConfiguration:(CPSessionConfiguration * _Nonnull)sessionConfiguration contentStyleChanged:(CPContentStyle)contentStyle SWIFT_AVAILABILITY(ios,introduced=13.0);
  407. @end
  408. /// <code>CarPlaySearchController</code> is the main object responsible for managing the search feature on CarPlay.
  409. /// Messages declared in the <code>CPApplicationDelegate</code> protocol should be sent to this object in the containing application’s application delegate. Implement <code>CarPlaySearchControllerDelegate</code> in the containing application and assign an instance to the <code>delegate</code> property of your <code>CarPlaySearchController</code> instance.
  410. /// note:
  411. /// It is very important you have a single <code>CarPlaySearchController</code> instance at any given time.
  412. SWIFT_CLASS("_TtC16MapboxNavigation23CarPlaySearchController") SWIFT_AVAILABILITY(ios,introduced=12.0)
  413. @interface CarPlaySearchController : NSObject
  414. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  415. @end
  416. SWIFT_AVAILABILITY(ios,introduced=12.0)
  417. @interface CarPlaySearchController (SWIFT_EXTENSION(MapboxNavigation)) <CPListTemplateDelegate>
  418. - (void)listTemplate:(CPListTemplate * _Nonnull)listTemplate didSelectListItem:(CPListItem * _Nonnull)item completionHandler:(void (^ _Nonnull)(void))completionHandler;
  419. @end
  420. @class CPSearchTemplate;
  421. SWIFT_AVAILABILITY(ios,introduced=12.0)
  422. @interface CarPlaySearchController (SWIFT_EXTENSION(MapboxNavigation)) <CPSearchTemplateDelegate>
  423. - (void)searchTemplateSearchButtonPressed:(CPSearchTemplate * _Nonnull)searchTemplate;
  424. - (void)searchTemplate:(CPSearchTemplate * _Nonnull)searchTemplate updatedSearchText:(NSString * _Nonnull)searchText completionHandler:(void (^ _Nonnull)(NSArray<CPListItem *> * _Nonnull))completionHandler;
  425. - (void)searchTemplate:(CPSearchTemplate * _Nonnull)searchTemplate selectedResult:(CPListItem * _Nonnull)item completionHandler:(void (^ _Nonnull)(void))completionHandler;
  426. @end
  427. enum StyleType : NSInteger;
  428. @class NSURL;
  429. /// <code>Style</code> is a convenient wrapper for styling the appearance of various interface components throughout the Navigation UI.
  430. /// Styles are applied globally using <code>UIAppearance</code>. You should call <code>Style.apply()</code> to apply the style to the <code>NavigationViewController</code>.
  431. SWIFT_CLASS_NAMED("Style")
  432. @interface MBStyle : NSObject
  433. /// Sets the tint color for guidance arrow, highlighted text, progress bar and more.
  434. @property (nonatomic, strong) UIColor * _Nullable tintColor;
  435. /// Sets the font family for all labels.
  436. @property (nonatomic, copy) NSString * _Nullable fontFamily;
  437. /// Describes the situations in which the style should be used. By default, the style will be used during the daytime.
  438. @property (nonatomic) enum StyleType styleType;
  439. /// URL of the style to display on the map during turn-by-turn navigation.
  440. @property (nonatomic, copy) NSURL * _Nonnull mapStyleURL;
  441. /// URL of the style to display on the map when previewing a route, for example on CarPlay or your own route preview map.
  442. /// Defaults to same style as <code>mapStyleURL</code>.
  443. @property (nonatomic, copy) NSURL * _Nonnull previewMapStyleURL;
  444. /// Applies the style for all changed properties.
  445. - (void)apply;
  446. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  447. @end
  448. /// <code>DefaultStyle</code> is default style for Mapbox Navigation SDK.
  449. SWIFT_CLASS("_TtC16MapboxNavigation8DayStyle")
  450. @interface DayStyle : MBStyle
  451. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  452. - (void)apply;
  453. @end
  454. SWIFT_CLASS_NAMED("DismissButton")
  455. @interface MBDismissButton : MBButton
  456. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  457. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  458. @end
  459. /// :nodoc:
  460. SWIFT_CLASS_NAMED("DistanceLabel")
  461. @interface MBDistanceLabel : MBStylableLabel
  462. @property (nonatomic, strong) UIColor * _Nonnull valueTextColor;
  463. @property (nonatomic, strong) UIColor * _Nonnull unitTextColor;
  464. @property (nonatomic, strong) UIColor * _Nonnull valueTextColorHighlighted;
  465. @property (nonatomic, strong) UIColor * _Nonnull unitTextColorHighlighted;
  466. @property (nonatomic, strong) UIFont * _Nonnull valueFont;
  467. @property (nonatomic, strong) UIFont * _Nonnull unitFont;
  468. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  469. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  470. @end
  471. SWIFT_CLASS_NAMED("DistanceRemainingLabel")
  472. @interface MBDistanceRemainingLabel : MBStylableLabel
  473. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  474. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  475. @end
  476. /// :nodoc:
  477. SWIFT_CLASS("_TtC16MapboxNavigation16EndOfRouteButton")
  478. @interface EndOfRouteButton : MBStylableButton
  479. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  480. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  481. @end
  482. @class NSTextContainer;
  483. SWIFT_CLASS_NAMED("StylableTextView")
  484. @interface MBStylableTextView : UITextView
  485. @property (nonatomic, strong) UIColor * _Nonnull normalTextColor;
  486. - (nonnull instancetype)initWithFrame:(CGRect)frame textContainer:(NSTextContainer * _Nullable)textContainer OBJC_DESIGNATED_INITIALIZER SWIFT_AVAILABILITY(ios,introduced=7.0);
  487. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  488. @end
  489. /// :nodoc:
  490. SWIFT_CLASS("_TtC16MapboxNavigation21EndOfRouteCommentView")
  491. @interface EndOfRouteCommentView : MBStylableTextView
  492. - (nonnull instancetype)initWithFrame:(CGRect)frame textContainer:(NSTextContainer * _Nullable)textContainer OBJC_DESIGNATED_INITIALIZER SWIFT_AVAILABILITY(ios,introduced=7.0);
  493. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  494. @end
  495. /// :nodoc:
  496. SWIFT_CLASS("_TtC16MapboxNavigation21EndOfRouteContentView")
  497. @interface EndOfRouteContentView : UIView
  498. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  499. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  500. @end
  501. /// :nodoc:
  502. SWIFT_CLASS("_TtC16MapboxNavigation21EndOfRouteStaticLabel")
  503. @interface EndOfRouteStaticLabel : MBStylableLabel
  504. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  505. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  506. @end
  507. /// :nodoc:
  508. SWIFT_CLASS("_TtC16MapboxNavigation20EndOfRouteTitleLabel")
  509. @interface EndOfRouteTitleLabel : MBStylableLabel
  510. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  511. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  512. @end
  513. SWIFT_CLASS("_TtC16MapboxNavigation8ExitView")
  514. @interface ExitView : MBStylableView
  515. @property (nonatomic, strong) UIColor * _Nullable foregroundColor;
  516. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  517. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  518. @end
  519. @protocol UIViewControllerTransitionCoordinator;
  520. @class UIGestureRecognizer;
  521. @class UITouch;
  522. /// A view controller containing a grid of buttons the user can use to denote an issue their current navigation experience.
  523. SWIFT_CLASS("_TtC16MapboxNavigation22FeedbackViewController")
  524. @interface FeedbackViewController : UIViewController <UIGestureRecognizerDelegate>
  525. /// Instantly dismisses the FeedbackViewController if it is currently presented.
  526. - (void)dismissFeedback;
  527. - (void)encodeWithCoder:(NSCoder * _Nonnull)aCoder;
  528. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  529. - (void)viewDidLoad;
  530. - (void)viewDidAppear:(BOOL)animated;
  531. - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id <UIViewControllerTransitionCoordinator> _Nonnull)coordinator;
  532. - (BOOL)gestureRecognizer:(UIGestureRecognizer * _Nonnull)gestureRecognizer shouldReceiveTouch:(UITouch * _Nonnull)touch SWIFT_WARN_UNUSED_RESULT;
  533. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
  534. @end
  535. @class UICollectionView;
  536. @class UICollectionViewLayout;
  537. @class NSIndexPath;
  538. @interface FeedbackViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDelegateFlowLayout>
  539. - (CGSize)collectionView:(UICollectionView * _Nonnull)collectionView layout:(UICollectionViewLayout * _Nonnull)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  540. @end
  541. @interface FeedbackViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDelegate>
  542. - (void)collectionView:(UICollectionView * _Nonnull)collectionView didSelectItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath;
  543. @end
  544. @protocol UIViewControllerAnimatedTransitioning;
  545. @protocol UIViewControllerInteractiveTransitioning;
  546. @interface FeedbackViewController (SWIFT_EXTENSION(MapboxNavigation)) <UIViewControllerTransitioningDelegate>
  547. - (id <UIViewControllerAnimatedTransitioning> _Nullable)animationControllerForDismissedController:(UIViewController * _Nonnull)dismissed SWIFT_WARN_UNUSED_RESULT;
  548. - (id <UIViewControllerAnimatedTransitioning> _Nullable)animationControllerForPresentedController:(UIViewController * _Nonnull)presented presentingController:(UIViewController * _Nonnull)presenting sourceController:(UIViewController * _Nonnull)source SWIFT_WARN_UNUSED_RESULT;
  549. - (id <UIViewControllerInteractiveTransitioning> _Nullable)interactionControllerForDismissal:(id <UIViewControllerAnimatedTransitioning> _Nonnull)animator SWIFT_WARN_UNUSED_RESULT;
  550. @end
  551. @class UICollectionViewCell;
  552. @interface FeedbackViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDataSource>
  553. - (UICollectionViewCell * _Nonnull)collectionView:(UICollectionView * _Nonnull)collectionView cellForItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  554. - (NSInteger)numberOfSectionsInCollectionView:(UICollectionView * _Nonnull)collectionView SWIFT_WARN_UNUSED_RESULT;
  555. - (NSInteger)collectionView:(UICollectionView * _Nonnull)collectionView numberOfItemsInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
  556. @end
  557. /// A rounded button with an icon that is designed to float above <code>NavigationMapView</code>.
  558. SWIFT_CLASS_NAMED("FloatingButton")
  559. @interface MBFloatingButton : MBButton
  560. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  561. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  562. @end
  563. /// <code>GenericRouteShield</code> is a class to render routes that do not have route-shields.
  564. SWIFT_CLASS("_TtC16MapboxNavigation18GenericRouteShield")
  565. @interface GenericRouteShield : MBStylableView
  566. @property (nonatomic, strong) UIColor * _Nullable foregroundColor;
  567. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  568. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  569. @end
  570. SWIFT_CLASS_NAMED("HighlightedButton") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  571. @interface MBHighlightedButton : MBButton
  572. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  573. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  574. @end
  575. /// :nodoc:
  576. SWIFT_CLASS("_TtC16MapboxNavigation16InstructionLabel")
  577. @interface InstructionLabel : MBStylableLabel
  578. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  579. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  580. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  581. @end
  582. /// A banner view that contains the current step instruction and responds to tap and swipe gestures.
  583. /// This class responds and gets updated as the user progresses along a route according to the
  584. /// <code>NavigationComponent</code> and <code>BaseInstructionsBannerView</code> protocol.
  585. IB_DESIGNABLE
  586. SWIFT_CLASS("_TtC16MapboxNavigation22InstructionsBannerView")
  587. @interface InstructionsBannerView : BaseInstructionsBannerView
  588. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  589. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  590. @end
  591. /// :nodoc:
  592. SWIFT_CLASS("_TtC16MapboxNavigation20InstructionsCardCell")
  593. @interface InstructionsCardCell : UICollectionViewCell
  594. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  595. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  596. @end
  597. /// A container view for the information currently displayed in <code>InstructionsCardViewController</code>.
  598. SWIFT_CLASS("_TtC16MapboxNavigation29InstructionsCardContainerView")
  599. @interface InstructionsCardContainerView : MBStylableView
  600. /// Color of the background that will be used in case if distance to the next maneuver is higher
  601. /// than threshold distance, defined in <code>InstructionCardHighlightDistance</code>.
  602. @property (nonatomic, strong) UIColor * _Nonnull customBackgroundColor;
  603. /// Color of the background that will be used when remaining distance to the next maneuver is below
  604. /// threshold distance, defined in <code>InstructionCardHighlightDistance</code>.
  605. @property (nonatomic, strong) UIColor * _Nonnull highlightedBackgroundColor;
  606. /// Color of the separator between <code>InstructionsCardView</code> or <code>LanesView</code>/<code>NextBannerView</code>.
  607. @property (nonatomic, strong) UIColor * _Nonnull separatorColor;
  608. /// Color of the separator between <code>InstructionsCardView</code> or <code>LanesView</code>/<code>NextBannerView</code> that will
  609. /// be used when remaining distance to the next maneuver is below threshold distance, defined in
  610. /// <code>InstructionCardHighlightDistance</code>.
  611. @property (nonatomic, strong) UIColor * _Nonnull highlightedSeparatorColor;
  612. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  613. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder SWIFT_UNAVAILABLE;
  614. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  615. @end
  616. /// :nodoc:
  617. SWIFT_CLASS("_TtC16MapboxNavigation20InstructionsCardView")
  618. @interface InstructionsCardView : BaseInstructionsBannerView
  619. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  620. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  621. @end
  622. /// A view controller that displays the current maneuver instruction as a “card” resembling a user
  623. /// notification. A subsequent maneuver is always partially visible on one side of the view;
  624. /// swiping to one side reveals the full maneuver.
  625. /// This class is an alternative to the more traditional banner interface provided by the
  626. /// <code>TopBannerViewController</code> class. To use <code>InstructionsCardViewController</code>, create an instance of it
  627. /// and pass it into the <code>NavigationOptions(styles:navigationService:voiceController:topBanner:bottomBanner:)</code>
  628. /// method.
  629. SWIFT_CLASS("_TtC16MapboxNavigation30InstructionsCardViewController")
  630. @interface InstructionsCardViewController : UIViewController
  631. - (void)viewDidLoad;
  632. - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id <UIViewControllerTransitionCoordinator> _Nonnull)coordinator;
  633. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  634. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil OBJC_DESIGNATED_INITIALIZER;
  635. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  636. @end
  637. @interface InstructionsCardViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDelegateFlowLayout>
  638. - (CGSize)collectionView:(UICollectionView * _Nonnull)collectionView layout:(UICollectionViewLayout * _Nonnull)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  639. @end
  640. @class UIScrollView;
  641. @interface InstructionsCardViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDelegate>
  642. - (void)scrollViewWillBeginDragging:(UIScrollView * _Nonnull)scrollView;
  643. - (void)scrollViewWillEndDragging:(UIScrollView * _Nonnull)scrollView withVelocity:(CGPoint)velocity targetContentOffset:(CGPoint * _Nonnull)targetContentOffset;
  644. @end
  645. @interface InstructionsCardViewController (SWIFT_EXTENSION(MapboxNavigation)) <UICollectionViewDataSource>
  646. - (NSInteger)collectionView:(UICollectionView * _Nonnull)collectionView numberOfItemsInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
  647. - (UICollectionViewCell * _Nonnull)collectionView:(UICollectionView * _Nonnull)collectionView cellForItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  648. - (void)collectionView:(UICollectionView * _Nonnull)collectionView willDisplayCell:(UICollectionViewCell * _Nonnull)cell forItemAtIndexPath:(NSIndexPath * _Nonnull)indexPath;
  649. @end
  650. @class UIImage;
  651. /// A junction view shows an image depicting the layout of a highway junction.
  652. /// As the user approaches certain junctions, an enlarged illustration of the junction appears in this view to help the user understand a complex maneuver. A junction view only appears when the relevant data is available.
  653. SWIFT_CLASS("_TtC16MapboxNavigation12JunctionView")
  654. @interface JunctionView : UIImageView
  655. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  656. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  657. - (nonnull instancetype)initWithImage:(UIImage * _Nullable)image SWIFT_UNAVAILABLE;
  658. - (nonnull instancetype)initWithImage:(UIImage * _Nullable)image highlightedImage:(UIImage * _Nullable)highlightedImage SWIFT_UNAVAILABLE;
  659. @end
  660. /// :nodoc:
  661. SWIFT_CLASS("_TtC16MapboxNavigation8LaneView")
  662. @interface LaneView : UIView
  663. @property (nonatomic, readonly) CGSize intrinsicContentSize;
  664. /// Color of the maneuver direction (applied only when <code>LaneView.isUsable</code> is set to <code>true</code>). In case if
  665. /// <code>LaneView.showHighlightedColors</code> is set to <code>true</code> this value is not used, <code>LaneView.primaryColorHighlighted</code>
  666. /// is used instead.
  667. @property (nonatomic, strong) UIColor * _Nonnull primaryColor;
  668. /// Color of the directions that the lane is reserved for (except the one that is applicable to the
  669. /// current route). In case if <code>LaneView.showHighlightedColors</code> is set to <code>true</code> this value is not used,
  670. /// <code>LaneView.secondaryColorHighlighted</code> is used instead.
  671. @property (nonatomic, strong) UIColor * _Nonnull secondaryColor;
  672. /// Highlighted color of the directions that the lane is reserved for (except the one that is
  673. /// applicable to the current route).
  674. @property (nonatomic, strong) UIColor * _Nonnull primaryColorHighlighted;
  675. /// Highlighted color of the directions that the lane is reserved for (except the one that is applicable
  676. /// to the current route).
  677. @property (nonatomic, strong) UIColor * _Nonnull secondaryColorHighlighted;
  678. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  679. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  680. - (void)drawRect:(CGRect)rect;
  681. @end
  682. enum LanesStyleKitResizingBehavior : NSInteger;
  683. SWIFT_CLASS("_TtC16MapboxNavigation13LanesStyleKit")
  684. @interface LanesStyleKit : NSObject
  685. /// / Drawing Methods
  686. + (void)drawLaneSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  687. + (void)drawLaneStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size;
  688. + (void)drawLaneUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  689. + (void)drawLaneSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  690. + (void)drawLaneTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  691. + (void)drawLaneSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  692. + (void)drawLaneTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  693. + (void)drawLaneStraightUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  694. + (void)drawLaneUturnUsingUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  695. + (void)drawLaneSharpTurnUsingSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  696. + (void)drawLaneSlightTurnOrSharpTurnUsingSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  697. + (void)drawLaneTurnOrSharpTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  698. + (void)drawLaneSlightTurnOrUturnUsingUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  699. + (void)drawLaneSlightTurnOrTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  700. + (void)drawLaneStraightOrUturnUsingUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  701. + (void)drawLaneTurnOrUturnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  702. + (void)drawLaneTurnOrUturnUsingUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  703. + (void)drawLaneTurnOrSharpTurnUsingSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  704. + (void)drawLaneStraightOrSharpTurnUsingSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  705. + (void)drawLaneOppositeTurnOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  706. + (void)drawLaneSlightTurnOrSharpTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  707. + (void)drawLaneStraightOrUturnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  708. + (void)drawLaneStraightOrSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  709. + (void)drawLaneOppositeSlightTurnOrSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  710. + (void)drawLaneStraightOrTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  711. + (void)drawLaneSlightTurnOrUturnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  712. + (void)drawLaneStraightOrSlightTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  713. + (void)drawLaneStraightOrSharpTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  714. + (void)drawLaneStraightOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  715. + (void)drawLaneSlightTurnOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  716. + (void)drawLaneOppositeTurnOrSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  717. + (void)drawLaneOppositeSlightTurnOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  718. + (void)drawLaneStraightOrUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  719. + (void)drawLaneStraightOrSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  720. + (void)drawLaneStraightOrSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  721. + (void)drawLaneStraightOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  722. + (void)drawLaneSlightTurnOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  723. + (void)drawLaneSlightTurnOrSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  724. + (void)drawLaneSlightTurnOrUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  725. + (void)drawLaneTurnOrSharpTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  726. + (void)drawLaneTurnOrUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  727. + (void)drawLaneOppositeTurnOrSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  728. + (void)drawLaneOppositeTurnOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  729. + (void)drawLaneOppositeSlightTurnOrSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  730. + (void)drawLaneOppositeSlightTurnOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  731. + (void)drawLaneOppositeTurnOrStraightOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  732. + (void)drawLaneOppositeTurnOrStraightOrTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  733. + (void)drawLaneStraightOrTurnOrUturnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  734. + (void)drawLaneStraightOrTurnOrUturnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  735. + (void)drawLaneStraightOrTurnOrUturnUsingUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  736. + (void)drawLaneStraightOrSlightTurnOrTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  737. + (void)drawLaneStraightOrSlightTurnOrTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  738. + (void)drawLaneStraightOrSlightTurnOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  739. + (void)drawLaneOppositeTurnOrStraightOrSlightTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  740. + (void)drawLaneOppositeTurnOrStraightOrSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  741. + (void)drawLaneOppositeSlightTurnOrStraightOrTurnUsingTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  742. + (void)drawLaneOppositeSlightTurnOrStraightOrTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  743. + (void)drawLaneOppositeSlightTurnOrStraightOrSlightTurnUsingStraightWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  744. + (void)drawLaneOppositeSlightTurnOrStraightOrSlightTurnUsingSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  745. + (void)drawLaneOppositeSlightTurnOrStraightOrSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  746. + (void)drawLaneOppositeTurnOrStraightOrSlightTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  747. + (void)drawLaneOppositeTurnOrStraightOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  748. + (void)drawLaneOppositeSlightTurnOrStraightOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  749. + (void)drawLaneStraightOrTurnOrUturnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  750. + (void)drawLaneStraightOrSlightTurnOrTurnWithFrame:(CGRect)targetFrame resizing:(enum LanesStyleKitResizingBehavior)resizing secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size flipHorizontally:(BOOL)flipHorizontally;
  751. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  752. @end
  753. typedef SWIFT_ENUM_NAMED(NSInteger, LanesStyleKitResizingBehavior, "ResizingBehavior", closed) {
  754. LanesStyleKitResizingBehaviorAspectFit = 0,
  755. /// The content is proportionally resized to fit into the target rectangle.
  756. LanesStyleKitResizingBehaviorAspectFill = 1,
  757. /// The content is proportionally resized to completely fill the target rectangle.
  758. LanesStyleKitResizingBehaviorStretch = 2,
  759. /// The content is stretched to match the entire target rectangle.
  760. LanesStyleKitResizingBehaviorCenter = 3,
  761. };
  762. /// :nodoc:
  763. IB_DESIGNABLE
  764. SWIFT_CLASS("_TtC16MapboxNavigation9LanesView")
  765. @interface LanesView : UIView
  766. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  767. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  768. - (void)prepareForInterfaceBuilder;
  769. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  770. @end
  771. SWIFT_CLASS_NAMED("LineView") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  772. @interface MBLineView : UIView
  773. @property (nonatomic, strong) UIColor * _Nonnull lineColor;
  774. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  775. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  776. @end
  777. SWIFT_CLASS_NAMED("ManeuverContainerView") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  778. @interface MBManeuverContainerView : UIView
  779. @property (nonatomic) CGFloat height;
  780. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  781. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  782. @end
  783. /// A view that contains a simple image indicating a type of maneuver.
  784. IB_DESIGNABLE
  785. SWIFT_CLASS("_TtC16MapboxNavigation12ManeuverView")
  786. @interface ManeuverView : UIView
  787. @property (nonatomic, strong) UIColor * _Nonnull primaryColor;
  788. @property (nonatomic, strong) UIColor * _Nonnull secondaryColor;
  789. @property (nonatomic, strong) UIColor * _Nonnull primaryColorHighlighted;
  790. @property (nonatomic, strong) UIColor * _Nonnull secondaryColorHighlighted;
  791. - (void)drawRect:(CGRect)rect;
  792. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  793. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  794. @end
  795. enum MBManeuversStyleKitResizingBehavior : NSInteger;
  796. /// :nodoc:
  797. SWIFT_CLASS("_TtC16MapboxNavigation17ManeuversStyleKit")
  798. @interface ManeuversStyleKit : NSObject
  799. + (void)drawArrow180rightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  800. + (void)drawArrowrightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  801. + (void)drawArrowslightrightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  802. + (void)drawArrowstraightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  803. + (void)drawArrowsharprightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  804. + (void)drawArriveWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  805. + (void)drawStartingWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  806. + (void)drawDestinationWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  807. + (void)drawMergeWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size;
  808. + (void)drawForkWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size;
  809. + (void)drawOfframpWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size;
  810. + (void)drawArriverightWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  811. + (void)drawRoundaboutWithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor secondaryColor:(UIColor * _Nonnull)secondaryColor size:(CGSize)size roundabout_angle:(CGFloat)roundabout_angle roundabout_radius:(CGFloat)roundabout_radius;
  812. + (void)drawArriveright2WithFrame:(CGRect)targetFrame resizing:(enum MBManeuversStyleKitResizingBehavior)resizing primaryColor:(UIColor * _Nonnull)primaryColor size:(CGSize)size;
  813. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  814. @end
  815. typedef SWIFT_ENUM_NAMED(NSInteger, MBManeuversStyleKitResizingBehavior, "ResizingBehavior", closed) {
  816. MBManeuversStyleKitResizingBehaviorAspectFit = 0,
  817. /// The content is proportionally resized to fit into the target rectangle.
  818. MBManeuversStyleKitResizingBehaviorAspectFill = 1,
  819. /// The content is proportionally resized to completely fill the target rectangle.
  820. MBManeuversStyleKitResizingBehaviorStretch = 2,
  821. /// The content is stretched to match the entire target rectangle.
  822. MBManeuversStyleKitResizingBehaviorCenter = 3,
  823. };
  824. /// <code>SpeechSynthesizing</code> implementation, using <code>MapboxSpeech</code> framework. Uses pre-caching mechanism for upcoming instructions.
  825. SWIFT_CLASS("_TtC16MapboxNavigation23MapboxSpeechSynthesizer")
  826. @interface MapboxSpeechSynthesizer : NSObject
  827. - (nonnull instancetype)init SWIFT_UNAVAILABLE;
  828. + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
  829. @end
  830. @class AVAudioPlayer;
  831. @interface MapboxSpeechSynthesizer (SWIFT_EXTENSION(MapboxNavigation)) <AVAudioPlayerDelegate>
  832. - (void)audioPlayerDidFinishPlaying:(AVAudioPlayer * _Nonnull)player successfully:(BOOL)flag;
  833. @end
  834. SWIFT_CLASS_NAMED("MarkerView") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  835. @interface MBMarkerView : UIView
  836. @property (nonatomic, strong) UIColor * _Nonnull innerColor;
  837. @property (nonatomic, strong) UIColor * _Nonnull shadowColor;
  838. @property (nonatomic, strong) UIColor * _Nonnull pinColor;
  839. @property (nonatomic, strong) UIColor * _Nonnull strokeColor;
  840. @property (nonatomic, readonly) CGSize intrinsicContentSize;
  841. - (void)layoutSubviews;
  842. - (void)drawRect:(CGRect)rect;
  843. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  844. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  845. @end
  846. /// <code>NavigationCamera</code> class provides functionality, which allows to manage camera related states
  847. /// and transitions in a typical navigation scenarios. It’s fed with <code>CameraOptions</code> via the <code>ViewportDataSource</code>
  848. /// protocol and executes transitions using <code>CameraStateTransition</code> protocol.
  849. SWIFT_CLASS("_TtC16MapboxNavigation16NavigationCamera")
  850. @interface NavigationCamera : NSObject
  851. /// Call to this method immediately moves <code>NavigationCamera</code> to <code>NavigationCameraState.idle</code> state
  852. /// and stops all pending transitions.
  853. - (void)stop;
  854. - (nonnull instancetype)init SWIFT_UNAVAILABLE;
  855. + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
  856. @end
  857. /// An object that notifies a map view when the user’s location changes, minimizing the noise that normally accompanies location updates from a <code>CLLocationManager</code> object.
  858. /// If your application displays a <code>MapView</code> before starting turn-by-turn navigation, call <code>LocationManager.overrideLocationProvider(with:)</code> to override default location provider so that the map view always shows the location snapped to the road network. For example, use this class to show the user’s current location as they wander around town.
  859. /// This class depends on <code>NavigationLocationManager</code> to detect the user’s location as it changes.
  860. SWIFT_CLASS("_TtC16MapboxNavigation26NavigationLocationProvider")
  861. @interface NavigationLocationProvider : NSObject <CLLocationManagerDelegate>
  862. - (nonnull instancetype)init SWIFT_UNAVAILABLE;
  863. + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
  864. @end
  865. /// <code>NavigationMapView</code> is a subclass of <code>UIView</code>, which draws <code>MapView</code> on its surface and provides
  866. /// convenience functions for adding <code>Route</code> lines to a map.
  867. SWIFT_CLASS("_TtC16MapboxNavigation17NavigationMapView")
  868. @interface NavigationMapView : UIView
  869. @property (nonatomic, strong) UIColor * _Nonnull trafficUnknownColor;
  870. @property (nonatomic, strong) UIColor * _Nonnull trafficLowColor;
  871. @property (nonatomic, strong) UIColor * _Nonnull trafficModerateColor;
  872. @property (nonatomic, strong) UIColor * _Nonnull trafficHeavyColor;
  873. @property (nonatomic, strong) UIColor * _Nonnull trafficSevereColor;
  874. @property (nonatomic, strong) UIColor * _Nonnull alternativeTrafficUnknownColor;
  875. @property (nonatomic, strong) UIColor * _Nonnull alternativeTrafficLowColor;
  876. @property (nonatomic, strong) UIColor * _Nonnull alternativeTrafficModerateColor;
  877. @property (nonatomic, strong) UIColor * _Nonnull alternativeTrafficHeavyColor;
  878. @property (nonatomic, strong) UIColor * _Nonnull alternativeTrafficSevereColor;
  879. @property (nonatomic, strong) UIColor * _Nonnull routeRestrictedAreaColor;
  880. @property (nonatomic, strong) UIColor * _Nonnull routeCasingColor;
  881. @property (nonatomic, strong) UIColor * _Nonnull routeAlternateColor;
  882. @property (nonatomic, strong) UIColor * _Nonnull routeAlternateCasingColor;
  883. @property (nonatomic, strong) UIColor * _Nonnull traversedRouteColor;
  884. @property (nonatomic, strong) UIColor * _Nonnull maneuverArrowColor;
  885. @property (nonatomic, strong) UIColor * _Nonnull maneuverArrowStrokeColor;
  886. /// Color of the buildings, which were found at specific coordinates by calling
  887. /// <code>NavigationMapView.highlightBuildings(at:in3D:extrudeAll:completion:)</code> and when <code>extrudeAll</code>
  888. /// parameter is set to <code>false</code>.
  889. @property (nonatomic, strong) UIColor * _Nonnull buildingHighlightColor;
  890. /// Color of all other buildings, which will be highlighted after calling
  891. /// <code>NavigationMapView.highlightBuildings(at:in3D:extrudeAll:completion:)</code> and when <code>extrudeAll</code>
  892. /// parameter is set to <code>true</code>.
  893. @property (nonatomic, strong) UIColor * _Nonnull buildingDefaultColor;
  894. /// Allows to control current user location styling based on accuracy authorization permission on iOS 14 and above.
  895. /// If <code>false</code>, user location will be drawn based on style, which was set in <code>NavigationMapView.userLocationStyle</code>.
  896. /// If <code>true</code>, <code>UserHaloCourseView</code> will be shown.
  897. @property (nonatomic) BOOL reducedAccuracyActivatedMode;
  898. @property (nonatomic, strong) UIColor * _Nonnull routeDurationAnnotationSelectedColor;
  899. @property (nonatomic, strong) UIColor * _Nonnull routeDurationAnnotationColor;
  900. @property (nonatomic, strong) UIColor * _Nonnull routeDurationAnnotationSelectedTextColor;
  901. @property (nonatomic, strong) UIColor * _Nonnull routeDurationAnnotationTextColor;
  902. /// List of Mapbox Maps font names to be used for any symbol layers added by the Navigation SDK.
  903. /// These are used for features such as Route Duration Annotations that are optionally added during route preview.
  904. /// See https://docs.mapbox.com/ios/maps/api/6.3.0/customizing-fonts.html for more information about server-side fonts.
  905. @property (nonatomic, copy) NSArray<NSString *> * _Nonnull routeDurationAnnotationFontNames;
  906. /// Initializes a newly allocated <code>NavigationMapView</code> object with the specified frame rectangle.
  907. /// \param frame The frame rectangle for the <code>NavigationMapView</code>.
  908. ///
  909. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  910. /// Returns a <code>NavigationMapView</code> object initialized from data in a given unarchiver.
  911. /// \param coder An unarchiver object.
  912. ///
  913. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  914. @end
  915. @interface NavigationMapView (SWIFT_EXTENSION(MapboxNavigation)) <UIGestureRecognizerDelegate>
  916. - (BOOL)gestureRecognizer:(UIGestureRecognizer * _Nonnull)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer * _Nonnull)otherGestureRecognizer SWIFT_WARN_UNUSED_RESULT;
  917. @end
  918. @class CLLocationManager;
  919. @interface NavigationMapView (SWIFT_EXTENSION(MapboxNavigation)) <CLLocationManagerDelegate>
  920. - (void)locationManager:(CLLocationManager * _Nonnull)manager didChangeAuthorizationStatus:(CLAuthorizationStatus)status;
  921. - (void)locationManagerDidChangeAuthorization:(CLLocationManager * _Nonnull)manager SWIFT_AVAILABILITY(ios,introduced=14.0);
  922. @end
  923. /// A view that represents the root view of the MapboxNavigation drop-in UI.
  924. /// <h2>Components</h2>
  925. /// <ol>
  926. /// <li>
  927. /// InstructionsBannerView
  928. /// </li>
  929. /// <li>
  930. /// InformationStackView
  931. /// </li>
  932. /// <li>
  933. /// BottomBannerView
  934. /// </li>
  935. /// <li>
  936. /// ResumeButton
  937. /// </li>
  938. /// <li>
  939. /// WayNameLabel
  940. /// </li>
  941. /// <li>
  942. /// FloatingStackView
  943. /// </li>
  944. /// <li>
  945. /// NavigationMapView
  946. /// </li>
  947. /// <li>
  948. /// SpeedLimitView
  949. /// </li>
  950. /// </ol>
  951. /// \code
  952. /// +--------------------+
  953. /// | 1 |
  954. /// +--------------------+
  955. /// | 2 |
  956. /// +---+------------+---+
  957. /// | 8 | | |
  958. /// +---+ | 6 |
  959. /// | | |
  960. /// | 7 +---+
  961. /// | |
  962. /// | |
  963. /// | |
  964. /// +------------+ |
  965. /// | 4 || 5 | |
  966. /// +------------+-------+
  967. /// | 3 |
  968. /// +--------------------+
  969. ///
  970. /// \endcode
  971. IB_DESIGNABLE
  972. SWIFT_CLASS("_TtC16MapboxNavigation14NavigationView")
  973. @interface NavigationView : UIView
  974. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  975. - (void)prepareForInterfaceBuilder;
  976. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  977. @end
  978. @interface NavigationView (SWIFT_EXTENSION(MapboxNavigation))
  979. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  980. @end
  981. @protocol UIContentContainer;
  982. /// <code>NavigationViewController</code> is a fully-featured user interface for turn-by-turn navigation. Do not confuse it with the <code>NavigationController</code> class in UIKit.
  983. /// You initialize a navigation view controller based on a predefined <code>RouteResponse</code> and <code>NavigationOptions</code>. As the user progresses along the route, the navigation view controller shows their surroundings and the route line on a map. Banners above and below the map display key information pertaining to the route. A list of steps and a feedback mechanism are accessible via the navigation view controller.
  984. /// Route initialization should be configured before view controller’s <code>view</code> is loaded. Usually, that is automatically done during any of the <code>init</code>s, but you may also change this settings via <code>prepareViewLoading(routeResponse:, routeIndex:, routeOptions:, navigationOptions:)</code> methods. For example that could be handy while configuring a ViewController for a <code>UIStoryboardSegue</code>.
  985. /// To be informed of significant events and decision points as the user progresses along the route, set the <code>NavigationService.delegate</code> property of the <code>NavigationService</code> that you provide when creating the navigation options.
  986. /// <code>CarPlayNavigationViewController</code> manages the corresponding user interface on a CarPlay screen.
  987. /// important:
  988. /// Creating an instance of this type with parameters that uses <code>RouteController</code> with will start an Active
  989. /// Guidance session. The trip session is stopped when the instance is deallocated. For more info read the
  990. /// <a href="https://docs.mapbox.com/ios/beta/navigation/guides/pricing/">Pricing Guide</a>.
  991. SWIFT_CLASS("_TtC16MapboxNavigation24NavigationViewController")
  992. @interface NavigationViewController : UIViewController
  993. /// The <code>NavigationMapView</code> displayed inside the view controller.
  994. /// note:
  995. /// Do not change <code>NavigationMapView.delegate</code> property; instead, implement the corresponding methods on <code>NavigationViewControllerDelegate</code>.
  996. @property (nonatomic, readonly, strong) NavigationMapView * _Nullable navigationMapView;
  997. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  998. - (void)loadView;
  999. - (void)viewDidLoad;
  1000. - (void)viewWillAppear:(BOOL)animated;
  1001. - (void)viewDidAppear:(BOOL)animated;
  1002. - (void)viewWillDisappear:(BOOL)animated;
  1003. - (void)viewDidDisappear:(BOOL)animated;
  1004. - (void)viewDidLayoutSubviews;
  1005. - (void)preferredContentSizeDidChangeForChildContentContainer:(id <UIContentContainer> _Nonnull)container;
  1006. @property (nonatomic, readonly) UIStatusBarStyle preferredStatusBarStyle;
  1007. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
  1008. @end
  1009. /// :nodoc:
  1010. IB_DESIGNABLE
  1011. SWIFT_CLASS("_TtC16MapboxNavigation14NextBannerView")
  1012. @interface NextBannerView : UIView
  1013. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  1014. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1015. - (void)prepareForInterfaceBuilder;
  1016. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  1017. @end
  1018. /// :nodoc:
  1019. SWIFT_CLASS("_TtC16MapboxNavigation20NextInstructionLabel")
  1020. @interface NextInstructionLabel : InstructionLabel
  1021. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1022. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1023. @end
  1024. /// <code>NightStyle</code> is the default night style for Mapbox Navigation SDK. Only will be applied when necessary and if <code>automaticallyAdjustStyleForSunPosition</code>.
  1025. SWIFT_CLASS("_TtC16MapboxNavigation10NightStyle")
  1026. @interface NightStyle : DayStyle
  1027. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  1028. - (void)apply;
  1029. @end
  1030. /// An object that notifies a map view when the user’s location changes, minimizing the noise that normally accompanies location updates from a <code>CLLocationManager</code> object.
  1031. /// Unlike <code>Router</code> classes such as <code>RouteController</code> and <code>LegacyRouteController</code>, this class operates without a predefined route, matching the user’s location to the road network at large. If your application displays a <code>MapView</code> before starting turn-by-turn navigation, call <code>LocationManager.overrideLocationProvider(with:)</code> to override default location provider so that the map view always shows the location snapped to the road network. For example, use this class to show the user’s current location as they wander around town.
  1032. /// This class depends on <code>PassiveLocationManager</code> to detect the user’s location as it changes. If you want location updates but do not need to display them on a map and do not want a dependency on the MapboxNavigation module, you can use <code>PassiveLocationManager</code> instead of this class.
  1033. SWIFT_CLASS("_TtC16MapboxNavigation23PassiveLocationProvider")
  1034. @interface PassiveLocationProvider : NSObject
  1035. - (nonnull instancetype)init SWIFT_UNAVAILABLE;
  1036. + (nonnull instancetype)new SWIFT_UNAVAILABLE_MSG("-init is unavailable");
  1037. @end
  1038. /// :nodoc:
  1039. SWIFT_CLASS_NAMED("PrimaryLabel")
  1040. @interface MBPrimaryLabel : InstructionLabel
  1041. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1042. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1043. @end
  1044. SWIFT_CLASS_NAMED("ProgressBar") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  1045. @interface MBProgressBar : UIView
  1046. @property (nonatomic, strong) UIColor * _Nonnull barColor;
  1047. @property (nonatomic, readonly, copy) NSString * _Nonnull description;
  1048. - (void)layoutSubviews;
  1049. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1050. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1051. @end
  1052. SWIFT_CLASS_NAMED("ReportButton") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  1053. @interface MBReportButton : MBButton
  1054. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  1055. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1056. @end
  1057. /// :nodoc:
  1058. IB_DESIGNABLE
  1059. SWIFT_CLASS_NAMED("ResumeButton")
  1060. @interface MBResumeButton : UIControl
  1061. /// The tint color of the <code>ResumeButton</code>’s icon and title.
  1062. @property (nonatomic, strong) UIColor * _Null_unspecified tintColor;
  1063. /// The width of the <code>ResumeButton</code>’s border.
  1064. @property (nonatomic) CGFloat borderWidth;
  1065. /// The radius of the <code>ResumeButton</code>’s corner.
  1066. @property (nonatomic) CGFloat cornerRadius;
  1067. /// The color of the <code>ResumeButton</code>’s border.
  1068. @property (nonatomic, strong) UIColor * _Nullable borderColor;
  1069. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1070. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1071. - (void)prepareForInterfaceBuilder;
  1072. @end
  1073. @class NSNotification;
  1074. /// A route voice controller monitors turn-by-turn navigation events and triggers playing spoken instructions as audio using the instance of <code>SpeechSynthesizing</code> type.
  1075. /// You initialize a voice controller using a <code>NavigationService</code> instance. The voice controller observes when the navigation service hints that the user has passed a <em>spoken instruction point</em> and responds by calling it’s <code>speechSynthesizer</code> to handle the vocalization.
  1076. /// If you want to use your own custom <code>SpeechSynthesizing</code> implementation - also pass it during initialization. If no implementation is provided - <code>MultiplexedSpeechSynthesizer</code> will be used by default.
  1077. /// You can also subclass <code>RouteVoiceController</code> to implement you own mechanism of monitoring navgiation events and calling <code>speechSynthesizer</code>.
  1078. SWIFT_CLASS("_TtC16MapboxNavigation20RouteVoiceController")
  1079. @interface RouteVoiceController : NSObject <AVSpeechSynthesizerDelegate>
  1080. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER SWIFT_UNAVAILABLE_MSG("Use init(navigationService:) instead.");
  1081. - (void)didPassSpokenInstructionPointWithNotification:(NSNotification * _Nonnull)notification;
  1082. @end
  1083. /// :nodoc:
  1084. SWIFT_CLASS_NAMED("SecondaryLabel")
  1085. @interface MBSecondaryLabel : InstructionLabel
  1086. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1087. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1088. @end
  1089. SWIFT_CLASS_NAMED("SeparatorView")
  1090. @interface MBSeparatorView : UIView
  1091. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1092. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1093. @end
  1094. enum SpeedLimitStyleKitResizingBehavior : NSInteger;
  1095. SWIFT_CLASS("_TtC16MapboxNavigation18SpeedLimitStyleKit")
  1096. @interface SpeedLimitStyleKit : NSObject
  1097. /// / Drawing Methods
  1098. + (void)drawMUTCDWithFrame:(CGRect)targetFrame resizing:(enum SpeedLimitStyleKitResizingBehavior)resizing signBackColor:(UIColor * _Nonnull)signBackColor strokeColor:(UIColor * _Nonnull)strokeColor limit:(NSString * _Nonnull)limit legend:(NSString * _Nonnull)legend;
  1099. + (void)drawViennaWithFrame:(CGRect)targetFrame resizing:(enum SpeedLimitStyleKitResizingBehavior)resizing signBackColor:(UIColor * _Nonnull)signBackColor strokeColor:(UIColor * _Nonnull)strokeColor regulatoryColor:(UIColor * _Nonnull)regulatoryColor limit:(NSString * _Nonnull)limit;
  1100. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  1101. @end
  1102. typedef SWIFT_ENUM_NAMED(NSInteger, SpeedLimitStyleKitResizingBehavior, "ResizingBehavior", closed) {
  1103. SpeedLimitStyleKitResizingBehaviorAspectFit = 0,
  1104. /// The content is proportionally resized to fit into the target rectangle.
  1105. SpeedLimitStyleKitResizingBehaviorAspectFill = 1,
  1106. /// The content is proportionally resized to completely fill the target rectangle.
  1107. SpeedLimitStyleKitResizingBehaviorStretch = 2,
  1108. /// The content is stretched to match the entire target rectangle.
  1109. SpeedLimitStyleKitResizingBehaviorCenter = 3,
  1110. };
  1111. /// A view that displays a speed limit and resembles a real-world speed limit sign.
  1112. SWIFT_CLASS("_TtC16MapboxNavigation14SpeedLimitView")
  1113. @interface SpeedLimitView : UIView
  1114. /// The sign’s background color.
  1115. @property (nonatomic, strong) UIColor * _Nonnull signBackColor;
  1116. /// The color of the text on the sign.
  1117. /// This color is also used for the border of an MUTCD-style sign.
  1118. @property (nonatomic, strong) UIColor * _Nonnull textColor;
  1119. /// The color of the border of a regulatory sign according to the Vienna Convention.
  1120. @property (nonatomic, strong) UIColor * _Nonnull regulatoryBorderColor;
  1121. - (nonnull instancetype)initWithFrame:(CGRect)frame SWIFT_UNAVAILABLE;
  1122. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder SWIFT_UNAVAILABLE;
  1123. - (void)drawRect:(CGRect)rect;
  1124. @end
  1125. /// :nodoc:
  1126. /// A translucent bar that responds to tap and swipe gestures, similar to a scrubber or stepper control, and expands and collapses to maximize screen real estate.
  1127. IB_DESIGNABLE
  1128. SWIFT_CLASS("_TtC16MapboxNavigation10StatusView")
  1129. @interface StatusView : UIControl
  1130. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1131. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1132. @end
  1133. /// A banner view that contains the current step instruction along a route and responds to tap and swipe gestures.
  1134. SWIFT_CLASS("_TtC16MapboxNavigation20StepInstructionsView")
  1135. @interface StepInstructionsView : BaseInstructionsBannerView
  1136. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1137. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1138. @end
  1139. /// :nodoc:
  1140. SWIFT_CLASS_NAMED("StepListIndicatorView")
  1141. @interface MBDraggableView : UIView
  1142. @property (nonatomic, copy) NSArray<UIColor *> * _Nonnull gradientColors;
  1143. - (void)layoutSubviews;
  1144. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1145. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1146. @end
  1147. /// <code>UITableViewCell</code> instance that provides the ability to show a current step instruction along a route.
  1148. SWIFT_CLASS("_TtC16MapboxNavigation17StepTableViewCell")
  1149. @interface StepTableViewCell : UITableViewCell
  1150. - (nonnull instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString * _Nullable)reuseIdentifier SWIFT_UNAVAILABLE;
  1151. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1152. - (void)prepareForReuse;
  1153. @end
  1154. /// :nodoc:
  1155. SWIFT_CLASS("_TtC16MapboxNavigation19StepsBackgroundView")
  1156. @interface StepsBackgroundView : UIView
  1157. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1158. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1159. @end
  1160. /// :nodoc:
  1161. SWIFT_CLASS("_TtC16MapboxNavigation19StepsViewController")
  1162. @interface StepsViewController : UIViewController
  1163. - (void)viewDidLoad;
  1164. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil OBJC_DESIGNATED_INITIALIZER;
  1165. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1166. @end
  1167. @class UITableView;
  1168. @interface StepsViewController (SWIFT_EXTENSION(MapboxNavigation)) <UITableViewDelegate>
  1169. - (void)tableView:(UITableView * _Nonnull)tableView didSelectRowAtIndexPath:(NSIndexPath * _Nonnull)indexPath;
  1170. @end
  1171. @interface StepsViewController (SWIFT_EXTENSION(MapboxNavigation)) <UITableViewDataSource>
  1172. - (NSInteger)numberOfSectionsInTableView:(UITableView * _Nonnull)tableView SWIFT_WARN_UNUSED_RESULT;
  1173. - (NSInteger)tableView:(UITableView * _Nonnull)tableView numberOfRowsInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
  1174. - (CGFloat)tableView:(UITableView * _Nonnull)tableView heightForRowAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  1175. - (UITableViewCell * _Nonnull)tableView:(UITableView * _Nonnull)tableView cellForRowAtIndexPath:(NSIndexPath * _Nonnull)indexPath SWIFT_WARN_UNUSED_RESULT;
  1176. - (void)tableView:(UITableView * _Nonnull)tableView willDisplayCell:(UITableViewCell * _Nonnull)cell forRowAtIndexPath:(NSIndexPath * _Nonnull)indexPath;
  1177. - (CGFloat)tableView:(UITableView * _Nonnull)tableView heightForHeaderInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
  1178. - (UIView * _Nullable)tableView:(UITableView * _Nonnull)tableView viewForHeaderInSection:(NSInteger)section SWIFT_WARN_UNUSED_RESULT;
  1179. @end
  1180. SWIFT_CLASS("_TtC16MapboxNavigation14StyleKitMarker")
  1181. @interface StyleKitMarker : NSObject
  1182. /// / Drawing Methods
  1183. + (void)drawMarkerWithFrame:(CGRect)frame innerColor:(UIColor * _Nonnull)innerColor shadowColor:(UIColor * _Nonnull)shadowColor pinColor:(UIColor * _Nonnull)pinColor strokeColor:(UIColor * _Nonnull)strokeColor;
  1184. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  1185. @end
  1186. typedef SWIFT_ENUM(NSInteger, StyleType, closed) {
  1187. StyleTypeDay = 0,
  1188. StyleTypeNight = 1,
  1189. };
  1190. SWIFT_CLASS_NAMED("SubtitleLabel") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  1191. @interface MBSubtitleLabel : MBStylableLabel
  1192. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1193. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1194. @end
  1195. /// <code>SpeechSynthesizing</code> implementation, using <code>AVSpeechSynthesizer</code>.
  1196. SWIFT_CLASS("_TtC16MapboxNavigation23SystemSpeechSynthesizer")
  1197. @interface SystemSpeechSynthesizer : NSObject
  1198. - (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER;
  1199. @end
  1200. @class AVSpeechSynthesizer;
  1201. @class AVSpeechUtterance;
  1202. @interface SystemSpeechSynthesizer (SWIFT_EXTENSION(MapboxNavigation)) <AVSpeechSynthesizerDelegate>
  1203. - (void)speechSynthesizer:(AVSpeechSynthesizer * _Nonnull)synthesizer didStartSpeechUtterance:(AVSpeechUtterance * _Nonnull)utterance;
  1204. - (void)speechSynthesizer:(AVSpeechSynthesizer * _Nonnull)synthesizer didContinueSpeechUtterance:(AVSpeechUtterance * _Nonnull)utterance;
  1205. - (void)speechSynthesizer:(AVSpeechSynthesizer * _Nonnull)synthesizer didFinishSpeechUtterance:(AVSpeechUtterance * _Nonnull)utterance;
  1206. - (void)speechSynthesizer:(AVSpeechSynthesizer * _Nonnull)synthesizer didPauseSpeechUtterance:(AVSpeechUtterance * _Nonnull)utterance;
  1207. - (void)speechSynthesizer:(AVSpeechSynthesizer * _Nonnull)synthesizer didCancelSpeechUtterance:(AVSpeechUtterance * _Nonnull)utterance;
  1208. @end
  1209. SWIFT_CLASS_NAMED("TimeRemainingLabel")
  1210. @interface MBTimeRemainingLabel : MBStylableLabel
  1211. /// Sets the text color for no or unknown traffic.
  1212. @property (nonatomic, strong) UIColor * _Nonnull trafficUnknownColor;
  1213. /// Sets the text color for low traffic.
  1214. @property (nonatomic, strong) UIColor * _Nonnull trafficLowColor;
  1215. /// Sets the text color for moderate traffic.
  1216. @property (nonatomic, strong) UIColor * _Nonnull trafficModerateColor;
  1217. /// Sets the text color for heavy traffic.
  1218. @property (nonatomic, strong) UIColor * _Nonnull trafficHeavyColor;
  1219. /// Sets the text color for severe traffic.
  1220. @property (nonatomic, strong) UIColor * _Nonnull trafficSevereColor;
  1221. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1222. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1223. @end
  1224. SWIFT_CLASS_NAMED("TitleLabel") SWIFT_DEPRECATED_MSG("This class is no longer used.")
  1225. @interface MBTitleLabel : MBStylableLabel
  1226. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1227. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1228. @end
  1229. SWIFT_CLASS_NAMED("TopBannerView")
  1230. @interface MBTopBannerView : UIView
  1231. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1232. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1233. @end
  1234. /// A view controller that displays the current maneuver instruction as a “banner” flush with the edges of the containing view. The user swipes to one side to preview a subsequent maneuver.
  1235. /// This class is the default top banner view controller used by <code>NavigationOptions</code> and <code>NavigationViewController</code>. <code>InstructionsCardViewController</code> provides an alternative, user notification–like interface.
  1236. SWIFT_CLASS("_TtC16MapboxNavigation23TopBannerViewController")
  1237. @interface TopBannerViewController : UIViewController
  1238. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1239. - (nonnull instancetype)initWithNibName:(NSString * _Nullable)nibNameOrNil bundle:(NSBundle * _Nullable)nibBundleOrNil SWIFT_UNAVAILABLE;
  1240. - (void)viewDidLoad;
  1241. @end
  1242. @interface UICollectionViewFlowLayout (SWIFT_EXTENSION(MapboxNavigation))
  1243. @property (nonatomic, readonly) BOOL flipsHorizontallyInOppositeLayoutDirection;
  1244. @end
  1245. /// A view representing the user’s reduced accuracy location on screen.
  1246. SWIFT_CLASS("_TtC16MapboxNavigation18UserHaloCourseView")
  1247. @interface UserHaloCourseView : UIView
  1248. /// Sets the inner fill color of the user halo.
  1249. @property (nonatomic, strong) UIColor * _Nonnull haloColor;
  1250. /// Sets the ring fill color of the circle around the user halo.
  1251. @property (nonatomic, strong) UIColor * _Nonnull haloRingColor;
  1252. /// Sets the ring size by the radius of the user halo.
  1253. @property (nonatomic) double haloRadius;
  1254. /// Sets the halo ring border width.
  1255. @property (nonatomic) double haloBorderWidth;
  1256. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1257. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1258. - (void)traitCollectionDidChange:(UITraitCollection * _Nullable)previousTraitCollection;
  1259. @end
  1260. /// A view representing the user’s location on screen.
  1261. SWIFT_CLASS("_TtC16MapboxNavigation18UserPuckCourseView")
  1262. @interface UserPuckCourseView : UIView
  1263. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1264. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)aDecoder OBJC_DESIGNATED_INITIALIZER;
  1265. @property (nonatomic, strong) UIColor * _Nonnull puckColor;
  1266. @property (nonatomic, strong) UIColor * _Nonnull stalePuckColor SWIFT_DEPRECATED_MSG("No stale status in active navigation anymore.");
  1267. @property (nonatomic, strong) UIColor * _Nonnull fillColor;
  1268. @property (nonatomic, strong) UIColor * _Nonnull shadowColor;
  1269. @end
  1270. /// A label that is used to show a road name and a shield icon.
  1271. SWIFT_CLASS_NAMED("WayNameLabel")
  1272. @interface MBWayNameLabel : MBStylableLabel
  1273. @property (nonatomic, strong) UIColor * _Nonnull roadShieldBlackColor;
  1274. @property (nonatomic, strong) UIColor * _Nonnull roadShieldBlueColor;
  1275. @property (nonatomic, strong) UIColor * _Nonnull roadShieldGreenColor;
  1276. @property (nonatomic, strong) UIColor * _Nonnull roadShieldRedColor;
  1277. @property (nonatomic, strong) UIColor * _Nonnull roadShieldWhiteColor;
  1278. @property (nonatomic, strong) UIColor * _Nonnull roadShieldYellowColor;
  1279. @property (nonatomic, strong) UIColor * _Nonnull roadShieldOrangeColor;
  1280. @property (nonatomic, strong) UIColor * _Nonnull roadShieldDefaultColor;
  1281. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1282. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)coder OBJC_DESIGNATED_INITIALIZER;
  1283. @end
  1284. @class CALayer;
  1285. /// A host view for <code>WayNameLabel</code> that shows a road name and a shield icon.
  1286. /// <code>WayNameView</code> is hidden or shown depending on the road name information availability. In case if
  1287. /// such information is not present, <code>WayNameView</code> is automatically hidden. If you’d like to completely
  1288. /// hide <code>WayNameView</code> set <code>WayNameView.isHidden</code> property to <code>true</code>.
  1289. SWIFT_CLASS_NAMED("WayNameView")
  1290. @interface MBWayNameView : UIView
  1291. @property (nonatomic, readonly, strong) CALayer * _Nonnull layer;
  1292. /// The background color of the <code>WayNameView</code>.
  1293. @property (nonatomic, strong) UIColor * _Nullable backgroundColor;
  1294. /// The color of the <code>WayNameView</code>’s border.
  1295. @property (nonatomic, strong) UIColor * _Nullable borderColor;
  1296. /// The width of the <code>WayNameView</code>’s border.
  1297. @property (nonatomic) CGFloat borderWidth;
  1298. /// The radius of the <code>WayNameView</code>’s corner. By default corner radius is set to half of
  1299. /// <code>WayNameView</code>’s height.
  1300. @property (nonatomic) CGFloat cornerRadius;
  1301. - (nonnull instancetype)initWithFrame:(CGRect)frame OBJC_DESIGNATED_INITIALIZER;
  1302. - (nullable instancetype)initWithCoder:(NSCoder * _Nonnull)decoder OBJC_DESIGNATED_INITIALIZER;
  1303. - (void)layoutSubviews;
  1304. @end
  1305. #if __has_attribute(external_source_symbol)
  1306. # pragma clang attribute pop
  1307. #endif
  1308. #pragma clang diagnostic pop
  1309. #endif