~ModuleInitializer()
Public types | |
---|---|
InitializerFn)(App *app, void *context) | typedef Initialization function, which should initialize a single Firebase module and return the InitResult. |
Public functions | |
---|---|
Initialize(App *app, void *context, const InitializerFn *init_fns, size_t init_fns_count) | Future< void > Initialize Firebase modules by calling one or more user-supplied functions, each of which must initialize at most one library, and should return the InitResult of the initialization. |
Initialize(App *app, void *context, InitializerFn init_fn) | Future< void > Initialize one Firebase module by calling a single user-supplied function that should initialize a Firebase module and return the InitResult. |
InitializeLastResult() | Future< void > Get the result of the most recent call to. |
InitResult(*InitializerFn)(App*app,void*context)
Initialization function, which should initialize a single Firebase module and return the InitResult.
Future<void>Initialize(App*app,void*context,constInitializerFn*init_fns,size_tinit_fns_count)
Initialize Firebase modules by calling one or more user-supplied functions, each of which must initialize at most one library, and should return the InitResult of the initialization.
This function will run the initializers in order, checking the return value of each. On Android, if the InitResult returned is kInitResultFailedMissingDependency, this indicates that Google Play services is not available and a Firebase module requires it. This function will attempt to fix Google Play services, and will retry initializations where it left off, beginning with the one that failed.
Details | |||||||||
---|---|---|---|---|---|---|---|---|---|
Parameters |
| ||||||||
Returns | A future result. When all of the initializers are completed, the Future will be completed with Error() = 0. If an initializer fails and the situation cannot be fixed, the Future will be completed with Error() equal to the number of initializers that did not succeed (since they are run in order, this tells you which ones failed). |
Future<void>Initialize(App*app,void*context,InitializerFninit_fn)
Initialize one Firebase module by calling a single user-supplied function that should initialize a Firebase module and return the InitResult.
See also:Initialize(::firebase::App*, void*, const InitializerFn*) for more information.
Future<void>InitializeLastResult()
Get the result of the most recent call to.
See also:Initialize().
ModuleInitializer()
virtual~ModuleInitializer()
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-01-23 UTC.