You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: android-sdk/src/main/java/com/optimizely/ab/android/sdk/OptimizelyUserContextAndroid.java
+16-6Lines changed: 16 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -266,21 +266,25 @@ public void decideAllAsync(@NonNull OptimizelyDecisionsCallback callback) {
266
266
/**
267
267
* Returns a decision result ({@link OptimizelyDecision}) for a given flag key and a user context, which contains all data required to deliver the flag.
268
268
* <p>
269
-
* Note: Despite the "Async" name, this method performs blocking synchronous decision-making.
270
-
* For true asynchronous decision-making with callbacks, use the callback-based decideAsync() methods.
269
+
* Note: This method blocks the calling thread until the decision is complete.
270
+
* It should only be called from a background thread.
271
+
* For callback-based asynchronous decision-making, use decideAsync() methods.
271
272
* </p>
272
273
* @param key A flag key for which a decision will be made.
273
274
* @param options A list of options for decision-making.
* Returns a decision result ({@link OptimizelyDecision}) for a given flag key and a user context, which contains all data required to deliver the flag.
283
-
*
284
+
* <p>
285
+
* Note: This method blocks the calling thread until the decision is complete.
286
+
* It should only be called from a background thread.
287
+
* </p>
284
288
* @param key A flag key for which a decision will be made.
285
289
* @return A decision result.
286
290
*/
@@ -315,7 +319,10 @@ public Map<String, OptimizelyDecision> decideForKeysAsync(@NonNull List<String>
315
319
316
320
/**
317
321
* Returns a key-map of decision results ({@link OptimizelyDecision}) for all active flag keys.
318
-
*
322
+
* <p>
323
+
* Note: This method blocks the calling thread until decisions are complete.
324
+
* It should only be called from a background thread.
325
+
* </p>
319
326
* @param options A list of options for decision-making.
320
327
* @return All decision results mapped by flag keys.
321
328
*/
@@ -325,7 +332,10 @@ public Map<String, OptimizelyDecision> decideAllAsync(@NonNull List<OptimizelyDe
325
332
326
333
/**
327
334
* Returns a key-map of decision results ({@link OptimizelyDecision}) for all active flag keys.
328
-
*
335
+
* <p>
336
+
* Note: This method blocks the calling thread until decisions are complete.
337
+
* It should only be called from a background thread.
338
+
* </p>
329
339
* @return A dictionary of all decision results, mapped by flag keys.
0 commit comments