FirebaseRemoteConfig class

The entry point for accessing Remote Config.

You can get an instance by calling FirebaseRemoteConfig.instance. Note FirebaseRemoteConfig.instance is async.

Inheritance
  • Object
  • PlatformInterface
  • FirebasePluginPlatform
  • FirebaseRemoteConfig
Available extensions

Properties

app FirebaseApp
The FirebaseApp this instance was initialized with.
final
hashCode int
The hash code for this object.
no setterinherited
lastFetchStatus RemoteConfigFetchStatus
Returns the status of the last fetch attempt.
no setter
lastFetchTime DateTime
Returns the DateTime of the last successful fetch.
no setter
onConfigUpdated Stream<RemoteConfigUpdate>
Starts listening for real-time config updates from the Remote Config backend and automatically fetches updates from the RC backend when they are available.
no setter
pluginConstants Map
Returns any plugin constants this plugin app instance has initialized.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
settings RemoteConfigSettings
Returns the RemoteConfigSettings of the current instance.
no setter
versionInfo VersionInfo

Available on FirebaseRemoteConfig, provided by the RemoteConfigExtension extension

no setter

Methods

activate() Future<bool>
Makes the last fetched config available to getters.
ensureInitialized() Future<void>
Ensures the last activated config are available to getters.
fetch() Future<void>
Fetches and caches configuration from the Remote Config service.
fetchAndActivate() Future<bool>
Performs a fetch and activate operation, as a convenience.
getAll() Map<String, RemoteConfigValue>
Returns a Map of all Remote Config parameters.
getBool(String key) bool
Gets the value for a given key as a bool.
getDouble(String key) double
Gets the value for a given key as a double.
getInt(String key) int
Gets the value for a given key as an int.
getString(String key) String
Gets the value for a given key as a String.
getValue(String key) RemoteConfigValue
Gets the RemoteConfigValue for a given key.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setConfigSettings(RemoteConfigSettings remoteConfigSettings) Future<void>
Sets the RemoteConfigSettings for the current instance.
setDefaults(Map<String, dynamic> defaultParameters) Future<void>
Sets the default parameter values for the current instance. Only booleans, strings and numbers are supported as values of the map
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

instance FirebaseRemoteConfig
Returns an instance using the default FirebaseApp.
no setter

Static Methods

instanceFor({required FirebaseApp app}) FirebaseRemoteConfig
Returns an instance using the specified FirebaseApp.