promise

promise: Promise<boolean>

Promise that is resolved when the prefetch completes or is cancelled. Await this promise to ensure that the database has been fully downloaded before going offline, for example.

Notes:

  • resolves to true if the prefetch completed and the entire database is local, or false if it was aborted or failed.
  • it is not rejected on cancel. Some progress may (or may not) have been made by the request.
  • To monitor the progress being made during prefetch, call CloudContainer.queryDatabase periodically.

Defined in

Last Updated: 15 May, 2024