@@ -154,20 +154,21 @@ NS_SWIFT_NAME(RemoteConfig)
154
154
// / Returns the FIRRemoteConfig instance configured for the default Firebase app. This singleton
155
155
// / object contains the complete set of Remote Config parameter values available to the app,
156
156
// / including the Active Config and Default Config. This object also caches values fetched from the
157
- // / Remote Config Server until they are copied to the Active Config by calling activateFetched. When
158
- // / you fetch values from the Remote Config Server using the default Firebase namespace service, you
159
- // / should use this class method to create a shared instance of the FIRRemoteConfig object to ensure
160
- // / that your app will function properly with the Remote Config Server and the Firebase service.
157
+ // / Remote Config Server until they are copied to the Active Config by calling
158
+ // / `activateWithCompletion:`. When you fetch values from the Remote Config Server using the default
159
+ // / Firebase namespace service, you should use this class method to create a shared instance of the
160
+ // / FIRRemoteConfig object to ensure that your app will function properly with the Remote Config
161
+ // / Server and the Firebase service.
161
162
+ (nonnull FIRRemoteConfig *)remoteConfig NS_SWIFT_NAME (remoteConfig());
162
163
163
164
// / Returns the FIRRemoteConfig instance for your (non-default) Firebase appID. Note that Firebase
164
165
// / analytics does not work for non-default app instances. This singleton object contains the
165
166
// / complete set of Remote Config parameter values available to the app, including the Active Config
166
167
// / and Default Config. This object also caches values fetched from the Remote Config Server until
167
- // / they are copied to the Active Config by calling activateFetched . When you fetch values from the
168
- // / Remote Config Server using the default Firebase namespace service, you should use this class
169
- // / method to create a shared instance of the FIRRemoteConfig object to ensure that your app will
170
- // / function properly with the Remote Config Server and the Firebase service.
168
+ // / they are copied to the Active Config by calling `activateWithCompletion:` . When you fetch values
169
+ // / from the Remote Config Server using the default Firebase namespace service, you should use this
170
+ // / class method to create a shared instance of the FIRRemoteConfig object to ensure that your app
171
+ // / will function properly with the Remote Config Server and the Firebase service.
171
172
+ (nonnull FIRRemoteConfig *)remoteConfigWithApp:(nonnull FIRApp *)app
172
173
NS_SWIFT_NAME (remoteConfig(app:));
173
174
@@ -179,8 +180,8 @@ NS_SWIFT_NAME(RemoteConfig)
179
180
- (void )ensureInitializedWithCompletionHandler:
180
181
(void (^_Nonnull)(NSError *_Nullable initializationError))completionHandler;
181
182
#pragma mark - Fetch
182
- // / Fetches Remote Config data with a callback. Call activateFetched to make fetched data available
183
- // / to your app.
183
+ // / Fetches Remote Config data with a callback. Call `activateWithCompletion:` to make fetched data
184
+ // / available to your app.
184
185
// /
185
186
// / Note: This method uses a Firebase Installations token to identify the app instance, and once
186
187
// / it's called, it periodically sends data to the Firebase backend. (see
@@ -193,7 +194,7 @@ NS_SWIFT_NAME(RemoteConfig)
193
194
NSError *_Nullable error))completionHandler;
194
195
195
196
// / Fetches Remote Config data and sets a duration that specifies how long config data lasts.
196
- // / Call activateFetched to make fetched data available to your app.
197
+ // / Call `activateWithCompletion:` to make fetched data available to your app.
197
198
// /
198
199
// / Note: This method uses a Firebase Installations token to identify the app instance, and once
199
200
// / it's called, it periodically sends data to the Firebase backend. (see
@@ -246,16 +247,16 @@ NS_SWIFT_NAME(RemoteConfig)
246
247
// / @param key Config key.
247
248
- (nonnull FIRRemoteConfigValue *)configValueForKey:(nullable NSString *)key;
248
249
249
- // / Gets the config value of a given namespace and a given source .
250
+ // / Gets the config value of a given source from the default namespace .
250
251
// / @param key Config key.
251
252
// / @param source Config value source.
252
253
- (nonnull FIRRemoteConfigValue *)configValueForKey:(nullable NSString *)key
253
254
source:(FIRRemoteConfigSource)source;
254
255
255
- // / Gets all the parameter keys from a given source and a given namespace.
256
+ // / Gets all the parameter keys of a given source from the default namespace.
256
257
// /
257
258
// / @param source The config data source.
258
- // / @return An array of keys under the given source and namespace .
259
+ // / @return An array of keys under the given source.
259
260
- (nonnull NSArray <NSString *> *)allKeysFromSource:(FIRRemoteConfigSource)source;
260
261
261
262
// / Returns the set of parameter keys that start with the given prefix, from the default namespace
@@ -271,18 +272,19 @@ NS_SWIFT_NAME(RemoteConfig)
271
272
// / @param defaults A dictionary mapping a NSString * key to a NSObject * value.
272
273
- (void )setDefaults:(nullable NSDictionary <NSString *, NSObject *> *)defaults;
273
274
274
- // / Sets default configs from plist for default namespace;
275
+ // / Sets default configs from plist for default namespace.
276
+ // /
275
277
// / @param fileName The plist file name, with no file name extension. For example, if the plist file
276
278
// / is defaultSamples.plist, call:
277
279
// / [[FIRRemoteConfig remoteConfig] setDefaultsFromPlistFileName:@"defaultSamples"];
278
280
- (void )setDefaultsFromPlistFileName:(nullable NSString *)fileName
279
281
NS_SWIFT_NAME (setDefaults(fromPlist:));
280
282
281
- // / Returns the default value of a given key and a given namespace from the default config.
283
+ // / Returns the default value of a given key from the default config.
282
284
// /
283
285
// / @param key The parameter key of default config.
284
- // / @return Returns the default value of the specified key and namespace . Returns
285
- // / nil if the key or namespace doesn't exist in the default config.
286
+ // / @return Returns the default value of the specified key. Returns
287
+ // / nil if the key doesn't exist in the default config.
286
288
- (nullable FIRRemoteConfigValue *)defaultValueForKey:(nullable NSString *)key;
287
289
288
290
@end
0 commit comments