17
17
< a title ="Mixpanel Class Reference "> </ a >
18
18
< header >
19
19
< div class ="content-wrapper ">
20
- < p > < a href ="../index.html "> Mixpanel 4.3.1 Docs</ a > (81 % documented)</ p >
20
+ < p > < a href ="../index.html "> Mixpanel 4.4.0 Docs</ a > (77 % documented)</ p >
21
21
< p class ="header-right "> < a href ="https://github.com/mixpanel/mixpanel-swift "> < img src ="../img/gh.png " alt ="GitHub "/> View on GitHub</ a > </ p >
22
22
< div class ="header-right ">
23
23
< form role ="search " action ="../search.json ">
59
59
< li class ="nav-group-name ">
60
60
< a href ="../Enums.html "> Enumerations</ a >
61
61
< ul class ="nav-group-tasks ">
62
+ < li class ="nav-group-task ">
63
+ < a href ="../Enums/GzipError.html "> GzipError</ a >
64
+ </ li >
62
65
< li class ="nav-group-task ">
63
66
< a href ="../Enums/MixpanelLogLevel.html "> MixpanelLogLevel</ a >
64
67
</ li >
73
76
< li class ="nav-group-task ">
74
77
< a href ="../Extensions/Bool.html "> Bool</ a >
75
78
</ li >
79
+ < li class ="nav-group-task ">
80
+ < a href ="../Extensions/Data.html "> Data</ a >
81
+ </ li >
76
82
< li class ="nav-group-task ">
77
83
< a href ="../Extensions/Date.html "> Date</ a >
78
84
</ li >
@@ -175,9 +181,9 @@ <h1>Mixpanel</h1>
175
181
< li class ="item ">
176
182
< div >
177
183
< code >
178
- < a name ="/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties9serverURLAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgANtFZ "> </ a >
179
- < a name ="//apple_ref/swift/Method/initialize(token:trackAutomaticEvents:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:serverURL:) " class ="dashAnchor "> </ a >
180
- < a class ="token " href ="#/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties9serverURLAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgANtFZ "> initialize(token:< wbr > trackAutomaticEvents:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > serverURL:< wbr > )</ a >
184
+ < a name ="/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties9serverURL0P15GzipCompressionAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAOSbtFZ "> </ a >
185
+ < a name ="//apple_ref/swift/Method/initialize(token:trackAutomaticEvents:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:serverURL:useGzipCompression: ) " class ="dashAnchor "> </ a >
186
+ < a class ="token " href ="#/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties9serverURL0P15GzipCompressionAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAOSbtFZ "> initialize(token:< wbr > trackAutomaticEvents:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > serverURL: < wbr > useGzipCompression :< wbr > )</ a >
181
187
</ code >
182
188
</ div >
183
189
< div class ="height-container ">
@@ -210,7 +216,8 @@ <h4>Declaration</h4>
210
216
< span class ="nv "> optOutTrackingByDefault</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> ,</ span >
211
217
< span class ="nv "> useUniqueDistinctId</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> ,</ span >
212
218
< span class ="nv "> superProperties</ span > < span class ="p "> :</ span > < span class ="kt "> < a href ="../Typealiases.html#/s:8Mixpanel10Propertiesa "> Properties</ a > </ span > < span class ="p "> ?</ span > < span class ="o "> =</ span > < span class ="kc "> nil</ span > < span class ="p "> ,</ span >
213
- < span class ="nv "> serverURL</ span > < span class ="p "> :</ span > < span class ="kt "> String</ span > < span class ="p "> ?</ span > < span class ="o "> =</ span > < span class ="kc "> nil</ span > < span class ="p "> )</ span > < span class ="o "> -></ span > < span class ="kt "> < a href ="../Classes/MixpanelInstance.html "> MixpanelInstance</ a > </ span > </ code > </ pre >
219
+ < span class ="nv "> serverURL</ span > < span class ="p "> :</ span > < span class ="kt "> String</ span > < span class ="p "> ?</ span > < span class ="o "> =</ span > < span class ="kc "> nil</ span > < span class ="p "> ,</ span >
220
+ < span class ="nv "> useGzipCompression</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> )</ span > < span class ="o "> -></ span > < span class ="kt "> < a href ="../Classes/MixpanelInstance.html "> MixpanelInstance</ a > </ span > </ code > </ pre >
214
221
215
222
</ div >
216
223
</ div >
@@ -315,6 +322,18 @@ <h4>Parameters</h4>
315
322
</ div >
316
323
</ td >
317
324
</ tr >
325
+ < tr >
326
+ < td >
327
+ < code >
328
+ < em > useGzipCompression</ em >
329
+ </ code >
330
+ </ td >
331
+ < td >
332
+ < div >
333
+ < p > Optional. Whether to use gzip compression for network requests.</ p >
334
+ </ div >
335
+ </ td >
336
+ </ tr >
318
337
</ tbody >
319
338
</ table >
320
339
</ div >
@@ -329,9 +348,9 @@ <h4>Return Value</h4>
329
348
< li class ="item ">
330
349
< div >
331
350
< code >
332
- < a name ="/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties17proxyServerConfigAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAA05ProxywX0VtFZ "> </ a >
333
- < a name ="//apple_ref/swift/Method/initialize(token:trackAutomaticEvents:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:proxyServerConfig:) " class ="dashAnchor "> </ a >
334
- < a class ="token " href ="#/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties17proxyServerConfigAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAA05ProxywX0VtFZ "> initialize(token:< wbr > trackAutomaticEvents:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > proxyServerConfig:< wbr > )</ a >
351
+ < a name ="/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties17proxyServerConfig0P15GzipCompressionAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAA05ProxywX0VSbtFZ "> </ a >
352
+ < a name ="//apple_ref/swift/Method/initialize(token:trackAutomaticEvents:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:proxyServerConfig:useGzipCompression: ) " class ="dashAnchor "> </ a >
353
+ < a class ="token " href ="#/s:8MixpanelAAC10initialize5token20trackAutomaticEvents13flushInterval12instanceName23optOutTrackingByDefault19useUniqueDistinctId15superProperties17proxyServerConfig0P15GzipCompressionAA0A8InstanceCSS_SbSdSSSgS2bSDySSAA0A4Type_pGSgAA05ProxywX0VSbtFZ "> initialize(token:< wbr > trackAutomaticEvents:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > proxyServerConfig: < wbr > useGzipCompression :< wbr > )</ a >
335
354
</ code >
336
355
</ div >
337
356
< div class ="height-container ">
@@ -364,7 +383,8 @@ <h4>Declaration</h4>
364
383
< span class ="nv "> optOutTrackingByDefault</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> ,</ span >
365
384
< span class ="nv "> useUniqueDistinctId</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> ,</ span >
366
385
< span class ="nv "> superProperties</ span > < span class ="p "> :</ span > < span class ="kt "> < a href ="../Typealiases.html#/s:8Mixpanel10Propertiesa "> Properties</ a > </ span > < span class ="p "> ?</ span > < span class ="o "> =</ span > < span class ="kc "> nil</ span > < span class ="p "> ,</ span >
367
- < span class ="nv "> proxyServerConfig</ span > < span class ="p "> :</ span > < span class ="kt "> < a href ="../Structs/ProxyServerConfig.html "> ProxyServerConfig</ a > </ span > < span class ="p "> )</ span > < span class ="o "> -></ span > < span class ="kt "> < a href ="../Classes/MixpanelInstance.html "> MixpanelInstance</ a > </ span > </ code > </ pre >
386
+ < span class ="nv "> proxyServerConfig</ span > < span class ="p "> :</ span > < span class ="kt "> < a href ="../Structs/ProxyServerConfig.html "> ProxyServerConfig</ a > </ span > < span class ="p "> ,</ span >
387
+ < span class ="nv "> useGzipCompression</ span > < span class ="p "> :</ span > < span class ="kt "> Bool</ span > < span class ="o "> =</ span > < span class ="kc "> false</ span > < span class ="p "> )</ span > < span class ="o "> -></ span > < span class ="kt "> < a href ="../Classes/MixpanelInstance.html "> MixpanelInstance</ a > </ span > </ code > </ pre >
368
388
369
389
</ div >
370
390
</ div >
@@ -469,6 +489,18 @@ <h4>Parameters</h4>
469
489
</ div >
470
490
</ td >
471
491
</ tr >
492
+ < tr >
493
+ < td >
494
+ < code >
495
+ < em > useGzipCompression</ em >
496
+ </ code >
497
+ </ td >
498
+ < td >
499
+ < div >
500
+ < p > Optional. Whether to use gzip compression for network requests.</ p >
501
+ </ div >
502
+ </ td >
503
+ </ tr >
472
504
</ tbody >
473
505
</ table >
474
506
</ div >
@@ -484,8 +516,8 @@ <h4>Return Value</h4>
484
516
< div >
485
517
< code >
486
518
< a name ="/ "> </ a >
487
- < a name ="//apple_ref/swift/Method/initialize(token:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:serverURL:) " class ="dashAnchor "> </ a >
488
- < a class ="token " href ="#/ "> initialize(token:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > serverURL:< wbr > )</ a >
519
+ < a name ="//apple_ref/swift/Method/initialize(token:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:serverURL:useGzipCompression: ) " class ="dashAnchor "> </ a >
520
+ < a class ="token " href ="#/ "> initialize(token:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > serverURL:< wbr > useGzipCompression: < wbr > )</ a >
489
521
</ code >
490
522
</ div >
491
523
< div class ="height-container ">
@@ -513,8 +545,8 @@ <h4>Return Value</h4>
513
545
< div >
514
546
< code >
515
547
< a name ="/ "> </ a >
516
- < a name ="//apple_ref/swift/Method/initialize(token:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:proxyServerConfig:) " class ="dashAnchor "> </ a >
517
- < a class ="token " href ="#/ "> initialize(token:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > proxyServerConfig:< wbr > )</ a >
548
+ < a name ="//apple_ref/swift/Method/initialize(token:flushInterval:instanceName:optOutTrackingByDefault:useUniqueDistinctId:superProperties:proxyServerConfig:useGzipCompression: ) " class ="dashAnchor "> </ a >
549
+ < a class ="token " href ="#/ "> initialize(token:< wbr > flushInterval:< wbr > instanceName:< wbr > optOutTrackingByDefault:< wbr > useUniqueDistinctId:< wbr > superProperties:< wbr > proxyServerConfig:< wbr > useGzipCompression: < wbr > )</ a >
518
550
</ code >
519
551
</ div >
520
552
< div class ="height-container ">
@@ -621,6 +653,37 @@ <h4>Return Value</h4>
621
653
</ section >
622
654
</ div >
623
655
</ li >
656
+ < li class ="item ">
657
+ < div >
658
+ < code >
659
+ < a name ="/s:8MixpanelAAC16safeMainInstanceAA0aD0CSgyFZ "> </ a >
660
+ < a name ="//apple_ref/swift/Method/safeMainInstance() " class ="dashAnchor "> </ a >
661
+ < a class ="token " href ="#/s:8MixpanelAAC16safeMainInstanceAA0aD0CSgyFZ "> safeMainInstance()</ a >
662
+ </ code >
663
+ </ div >
664
+ < div class ="height-container ">
665
+ < div class ="pointer-container "> </ div >
666
+ < section class ="section ">
667
+ < div class ="pointer "> </ div >
668
+ < div class ="abstract ">
669
+ < p > Returns the main Mixpanel instance if it has been initialized.</ p >
670
+
671
+ </ div >
672
+ < div class ="declaration ">
673
+ < h4 > Declaration</ h4 >
674
+ < div class ="language ">
675
+ < p class ="aside-title "> Swift</ p >
676
+ < pre class ="highlight swift "> < code > < span class ="kd "> public</ span > < span class ="kd "> class</ span > < span class ="kd "> func</ span > < span class ="nf "> safeMainInstance</ span > < span class ="p "> ()</ span > < span class ="o "> -></ span > < span class ="kt "> < a href ="../Classes/MixpanelInstance.html "> MixpanelInstance</ a > </ span > < span class ="p "> ?</ span > </ code > </ pre >
677
+
678
+ </ div >
679
+ </ div >
680
+ < div >
681
+ < h4 > Return Value</ h4 >
682
+ < p > An optional MixpanelInstance, or nil if not yet initialized.</ p >
683
+ </ div >
684
+ </ section >
685
+ </ div >
686
+ </ li >
624
687
< li class ="item ">
625
688
< div >
626
689
< code >
@@ -718,7 +781,7 @@ <h4>Parameters</h4>
718
781
</ section >
719
782
</ section >
720
783
< section id ="footer ">
721
- < p > © 2025 < a class ="link " href ="http://mixpanel.com " target ="_blank " rel ="external noopener "> Mixpanel</ a > . All rights reserved. (Last updated: 2025-02-10 )</ p >
784
+ < p > © 2025 < a class ="link " href ="http://mixpanel.com " target ="_blank " rel ="external noopener "> Mixpanel</ a > . All rights reserved. (Last updated: 2025-03-31 )</ p >
722
785
< p > Generated by < a class ="link " href ="https://github.com/realm/jazzy " target ="_blank " rel ="external noopener "> jazzy ♪♫ v0.14.2</ a > , a < a class ="link " href ="https://realm.io " target ="_blank " rel ="external noopener "> Realm</ a > project.</ p >
723
786
</ section >
724
787
</ article >
0 commit comments