setOfflineRegionObserved method

Future<void> setOfflineRegionObserved(
  1. int regionId,
  2. RuntimeEventFlag events
)

Selects the events that the runtime reports about the download of the offline region regionId.

events holds bits of RuntimeEventFlag.allRuntimeEvents and replaces the region's previous selection. RuntimeEventFlag.none stops the region's events.

See mln_runtime_set_offline_region_observed in the C API reference.

Errors:

  • Status.notFound when the cache file has no region regionId.

Implementation

Future<void> setOfflineRegionObserved(
  int regionId,
  RuntimeEventFlag events,
) => _run(
  (arena, completion) => raw.mln_runtime_set_offline_region_observed(
    _handle.raw,
    regionId,
    events.rawValue,
    completion,
    nativeDiagnostic,
  ),
);