Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions OptimizelySwiftSDK.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -2110,6 +2110,24 @@
98F28A502E02DD6D00A86546 /* CmabClient.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A402E02DD6D00A86546 /* CmabClient.swift */; };
98F28A522E02E81500A86546 /* CMABClientTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A512E02E81500A86546 /* CMABClientTests.swift */; };
98F28A532E02E81500A86546 /* CMABClientTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A512E02E81500A86546 /* CMABClientTests.swift */; };
98F28A562E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A572E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A582E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A592E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5A2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5B2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5C2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5D2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5E2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A5F2E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A602E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A612E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A622E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A632E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A642E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A652E0451CC00A86546 /* CmabService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A552E0451CC00A86546 /* CmabService.swift */; };
98F28A672E05220300A86546 /* CmabServiceTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A662E05220300A86546 /* CmabServiceTests.swift */; };
98F28A682E05220300A86546 /* CmabServiceTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F28A662E05220300A86546 /* CmabServiceTests.swift */; };
BD1C3E8524E4399C0084B4DA /* SemanticVersion.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0B97DD93249D327F003DE606 /* SemanticVersion.swift */; };
BD64853C2491474500F30986 /* Optimizely.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E75167A22C520D400B2B157 /* Optimizely.h */; settings = {ATTRIBUTES = (Public, ); }; };
BD64853E2491474500F30986 /* Audience.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6E75169822C520D400B2B157 /* Audience.swift */; };
Expand Down Expand Up @@ -2565,6 +2583,8 @@
98F28A2D2E01968000A86546 /* CmabTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CmabTests.swift; sourceTree = "<group>"; };
98F28A402E02DD6D00A86546 /* CmabClient.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CmabClient.swift; sourceTree = "<group>"; };
98F28A512E02E81500A86546 /* CMABClientTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CMABClientTests.swift; sourceTree = "<group>"; };
98F28A552E0451CC00A86546 /* CmabService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CmabService.swift; sourceTree = "<group>"; };
98F28A662E05220300A86546 /* CmabServiceTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CmabServiceTests.swift; sourceTree = "<group>"; };
BD6485812491474500F30986 /* Optimizely.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Optimizely.framework; sourceTree = BUILT_PRODUCTS_DIR; };
C78CAF572445AD8D009FE876 /* OptimizelyJSON.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OptimizelyJSON.swift; sourceTree = "<group>"; };
C78CAF652446DB91009FE876 /* OptimizelyClientTests_OptimizelyJSON.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OptimizelyClientTests_OptimizelyJSON.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -3098,6 +3118,7 @@
8486180E286D0B8900B7F41B /* OdpManagerTests.swift */,
8486180D286D0B8900B7F41B /* OdpSegmentManagerTests.swift */,
98F28A512E02E81500A86546 /* CMABClientTests.swift */,
98F28A662E05220300A86546 /* CmabServiceTests.swift */,
8486180F286D0B8900B7F41B /* VuidManagerTests.swift */,
84861819286D188B00B7F41B /* OdpSegmentApiManagerTests.swift */,
8486181A286D188B00B7F41B /* OdpEventApiManagerTests.swift */,
Expand Down Expand Up @@ -3270,6 +3291,7 @@
isa = PBXGroup;
children = (
98F28A402E02DD6D00A86546 /* CmabClient.swift */,
98F28A552E0451CC00A86546 /* CmabService.swift */,
);
path = CMAB;
sourceTree = "<group>";
Expand Down Expand Up @@ -4343,6 +4365,7 @@
6E14CD752423F97600010234 /* OptimizelyConfig+ObjC.swift in Sources */,
6E14CD712423F96800010234 /* OptimizelyClient.swift in Sources */,
6E14CD842423F9A100010234 /* BatchEventBuilder.swift in Sources */,
98F28A5E2E0451CC00A86546 /* CmabService.swift in Sources */,
6E14CD6E2423F85E00010234 /* EventDispatcherTests_Batch.swift in Sources */,
6E14CDA92423F9C300010234 /* Utils.swift in Sources */,
98F28A472E02DD6D00A86546 /* CmabClient.swift in Sources */,
Expand Down Expand Up @@ -4416,6 +4439,7 @@
84E2E9782855875E001114AB /* OdpEventManager.swift in Sources */,
6E424CFA26324B620081004A /* DataStoreMemory.swift in Sources */,
6E424CFB26324B620081004A /* DataStoreUserDefaults.swift in Sources */,
98F28A652E0451CC00A86546 /* CmabService.swift in Sources */,
6E6522E4278E4F3800954EA1 /* OdpManager.swift in Sources */,
6E424CFC26324B620081004A /* DataStoreFile.swift in Sources */,
6E424CFD26324B620081004A /* DataStoreQueueStackImpl.swift in Sources */,
Expand Down Expand Up @@ -4574,6 +4598,7 @@
C78CAF592445AD8D009FE876 /* OptimizelyJSON.swift in Sources */,
848617C92863DC2700B7F41B /* OdpSegmentManager.swift in Sources */,
6E7518E922C520D400B2B157 /* ConditionHolder.swift in Sources */,
98F28A622E0451CC00A86546 /* CmabService.swift in Sources */,
6E75184122C520D400B2B157 /* Event.swift in Sources */,
6E7517C922C520D400B2B157 /* DefaultBucketer.swift in Sources */,
6E75181D22C520D400B2B157 /* BatchEventBuilder.swift in Sources */,
Expand Down Expand Up @@ -4667,6 +4692,7 @@
6E7516DE22C520D400B2B157 /* OPTUserProfileService.swift in Sources */,
6E75189022C520D400B2B157 /* Project.swift in Sources */,
6E75195C22C520D500B2B157 /* OPTBucketer.swift in Sources */,
98F28A572E0451CC00A86546 /* CmabService.swift in Sources */,
6E7518E422C520D400B2B157 /* ConditionLeaf.swift in Sources */,
6E7518F022C520D500B2B157 /* ConditionHolder.swift in Sources */,
98F28A442E02DD6D00A86546 /* CmabClient.swift in Sources */,
Expand Down Expand Up @@ -4830,6 +4856,7 @@
C78CAF7424482C86009FE876 /* OptimizelyClientTests_OptimizelyJSON.swift in Sources */,
6EC6DD3724ABF6990017D296 /* OptimizelyClient+Decide.swift in Sources */,
6E7516E622C520D400B2B157 /* OPTEventDispatcher.swift in Sources */,
98F28A612E0451CC00A86546 /* CmabService.swift in Sources */,
6EF8DE3724BF7D69008B9488 /* DecisionReasons.swift in Sources */,
6EC6DD4724ABF89B0017D296 /* OptimizelyUserContext.swift in Sources */,
6E7518F822C520D500B2B157 /* UserAttribute.swift in Sources */,
Expand Down Expand Up @@ -4904,6 +4931,7 @@
6E75188F22C520D400B2B157 /* Project.swift in Sources */,
6E75195B22C520D500B2B157 /* OPTBucketer.swift in Sources */,
6E7518E322C520D400B2B157 /* ConditionLeaf.swift in Sources */,
98F28A5D2E0451CC00A86546 /* CmabService.swift in Sources */,
6E7518EF22C520D400B2B157 /* ConditionHolder.swift in Sources */,
6E75182F22C520D400B2B157 /* BatchEvent.swift in Sources */,
6E75191F22C520D500B2B157 /* OPTNotificationCenter.swift in Sources */,
Expand Down Expand Up @@ -4959,6 +4987,7 @@
6E9B117422C5487100C22D81 /* DecisionServiceTests_Others.swift in Sources */,
6E9B116E22C5487100C22D81 /* LoggerTests.swift in Sources */,
84F6BADE27FD011B004BE62A /* OptimizelyUserContextTests_ODP_Decide.swift in Sources */,
98F28A5C2E0451CC00A86546 /* CmabService.swift in Sources */,
6E75180D22C520D400B2B157 /* DataStoreFile.swift in Sources */,
6E75178722C520D400B2B157 /* ArrayEventForDispatch+Extension.swift in Sources */,
6E75179F22C520D400B2B157 /* DataStoreQueueStackImpl+Extension.swift in Sources */,
Expand Down Expand Up @@ -5007,6 +5036,7 @@
6E75192D22C520D500B2B157 /* DataStoreQueueStack.swift in Sources */,
6E7516D322C520D400B2B157 /* OPTLogger.swift in Sources */,
6E75180122C520D400B2B157 /* DataStoreUserDefaults.swift in Sources */,
98F28A672E05220300A86546 /* CmabServiceTests.swift in Sources */,
98AC98472DB7B762001405DD /* BucketTests_HoldoutToVariation.swift in Sources */,
6E75175722C520D400B2B157 /* LogMessage.swift in Sources */,
98F28A242E01940500A86546 /* Cmab.swift in Sources */,
Expand Down Expand Up @@ -5153,6 +5183,7 @@
6E9B119622C5488300C22D81 /* AudienceTests.swift in Sources */,
6E7518B622C520D400B2B157 /* Group.swift in Sources */,
6E7516D422C520D400B2B157 /* OPTLogger.swift in Sources */,
98F28A602E0451CC00A86546 /* CmabService.swift in Sources */,
6E75183222C520D400B2B157 /* BatchEvent.swift in Sources */,
6E7518DA22C520D400B2B157 /* AttributeValue.swift in Sources */,
84640882281320F000CCF97D /* IntegrationTests.swift in Sources */,
Expand Down Expand Up @@ -5248,6 +5279,7 @@
6E9B115422C5486E00C22D81 /* LoggerTests.swift in Sources */,
6E7518DF22C520D400B2B157 /* ConditionLeaf.swift in Sources */,
6E75172D22C520D400B2B157 /* Constants.swift in Sources */,
98F28A5A2E0451CC00A86546 /* CmabService.swift in Sources */,
6E75172122C520D400B2B157 /* OptimizelyResult.swift in Sources */,
6E75186722C520D400B2B157 /* Rollout.swift in Sources */,
6E424C01263228FD0081004A /* AtomicDictionary.swift in Sources */,
Expand Down Expand Up @@ -5296,6 +5328,7 @@
6E75193322C520D500B2B157 /* OPTDataStore.swift in Sources */,
84861811286D0B8900B7F41B /* OdpSegmentManagerTests.swift in Sources */,
6E7517EF22C520D400B2B157 /* DataStoreMemory.swift in Sources */,
98F28A682E05220300A86546 /* CmabServiceTests.swift in Sources */,
6E75194B22C520D500B2B157 /* OPTDatafileHandler.swift in Sources */,
6E75195722C520D500B2B157 /* OPTBucketer.swift in Sources */,
98F28A2A2E01940500A86546 /* Cmab.swift in Sources */,
Expand Down Expand Up @@ -5437,6 +5470,7 @@
6E86CEA924FDC847005DAFED /* OptimizelyUserContext+ObjC.swift in Sources */,
6E9B118322C5488100C22D81 /* UserAttributeTests_Evaluate.swift in Sources */,
98F28A1D2E01940500A86546 /* Cmab.swift in Sources */,
98F28A582E0451CC00A86546 /* CmabService.swift in Sources */,
6E9B118E22C5488100C22D81 /* ProjectTests.swift in Sources */,
6E9B118022C5488100C22D81 /* AudienceTests.swift in Sources */,
6E7518B122C520D400B2B157 /* Group.swift in Sources */,
Expand Down Expand Up @@ -5563,6 +5597,7 @@
6E7517DA22C520D400B2B157 /* DefaultNotificationCenter.swift in Sources */,
6E7517E622C520D400B2B157 /* DefaultDecisionService.swift in Sources */,
984FE51F2CC8AA88004F6F41 /* UserProfileTracker.swift in Sources */,
98F28A5B2E0451CC00A86546 /* CmabService.swift in Sources */,
6E75171822C520D400B2B157 /* OptimizelyClient+ObjC.swift in Sources */,
98F28A452E02DD6D00A86546 /* CmabClient.swift in Sources */,
6E75174822C520D400B2B157 /* HandlerRegistryService.swift in Sources */,
Expand Down Expand Up @@ -5671,6 +5706,7 @@
6E7517DF22C520D400B2B157 /* DefaultNotificationCenter.swift in Sources */,
6E7517EB22C520D400B2B157 /* DefaultDecisionService.swift in Sources */,
984FE51D2CC8AA88004F6F41 /* UserProfileTracker.swift in Sources */,
98F28A562E0451CC00A86546 /* CmabService.swift in Sources */,
6E75171D22C520D400B2B157 /* OptimizelyClient+ObjC.swift in Sources */,
98F28A4A2E02DD6D00A86546 /* CmabClient.swift in Sources */,
6E75174D22C520D400B2B157 /* HandlerRegistryService.swift in Sources */,
Expand Down Expand Up @@ -5811,6 +5847,7 @@
C78CAF582445AD8D009FE876 /* OptimizelyJSON.swift in Sources */,
848617C82863DC2700B7F41B /* OdpSegmentManager.swift in Sources */,
6E75170622C520D400B2B157 /* OptimizelyClient.swift in Sources */,
98F28A642E0451CC00A86546 /* CmabService.swift in Sources */,
6E7518A022C520D400B2B157 /* FeatureFlag.swift in Sources */,
6E75174222C520D400B2B157 /* HandlerRegistryService.swift in Sources */,
6E75187022C520D400B2B157 /* Variation.swift in Sources */,
Expand Down Expand Up @@ -5904,6 +5941,7 @@
6E7517E222C520D400B2B157 /* DefaultDecisionService.swift in Sources */,
6E7516D822C520D400B2B157 /* OPTUserProfileService.swift in Sources */,
6E75188A22C520D400B2B157 /* Project.swift in Sources */,
98F28A5F2E0451CC00A86546 /* CmabService.swift in Sources */,
6E75195622C520D500B2B157 /* OPTBucketer.swift in Sources */,
6E7518DE22C520D400B2B157 /* ConditionLeaf.swift in Sources */,
98F28A4B2E02DD6D00A86546 /* CmabClient.swift in Sources */,
Expand Down Expand Up @@ -6017,6 +6055,7 @@
75C71A2E25E454460084187E /* Project.swift in Sources */,
75C71A2F25E454460084187E /* Experiment.swift in Sources */,
75C71A3025E454460084187E /* FeatureFlag.swift in Sources */,
98F28A592E0451CC00A86546 /* CmabService.swift in Sources */,
75C71A3125E454460084187E /* Group.swift in Sources */,
75C71A3225E454460084187E /* Variable.swift in Sources */,
848617DD2863E21200B7F41B /* OdpSegmentApiManager.swift in Sources */,
Expand Down Expand Up @@ -6119,6 +6158,7 @@
BD6485662491474500F30986 /* OptimizelyJSON.swift in Sources */,
848617CA2863DC2700B7F41B /* OdpSegmentManager.swift in Sources */,
BD6485672491474500F30986 /* OptimizelyClient.swift in Sources */,
98F28A632E0451CC00A86546 /* CmabService.swift in Sources */,
BD6485682491474500F30986 /* FeatureFlag.swift in Sources */,
BD6485692491474500F30986 /* HandlerRegistryService.swift in Sources */,
BD64856A2491474500F30986 /* Variation.swift in Sources */,
Expand Down
4 changes: 2 additions & 2 deletions Sources/CMAB/CmabClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ protocol CmabClient {
func fetchDecision(
ruleId: String,
userId: String,
attributes: [String: Any],
attributes: [String: Any?],
cmabUUID: String,
completion: @escaping (Result<String, Error>) -> Void
)
Expand All @@ -67,7 +67,7 @@ class DefaultCmabClient: CmabClient {
func fetchDecision(
ruleId: String,
userId: String,
attributes: [String: Any],
attributes: [String: Any?],
cmabUUID: String,
completion: @escaping (Result<String, Error>) -> Void
) {
Expand Down
Loading
Loading