buildServiceCacheOptions function

Options buildServiceCacheOptions({
  1. Options? options,
  2. Duration? maxStale,
  3. String? primaryKey,
  4. String? subKey,
  5. bool? forceRefresh,
})

try to get maxAge and maxStale from response headers. local settings will always overview the value get from service.

Implementation

Options buildServiceCacheOptions(
        {Options? options,
        Duration? maxStale,
        String? primaryKey,
        String? subKey,
        bool? forceRefresh}) =>
    buildConfigurableCacheOptions(
        options: options,
        maxStale: maxStale,
        primaryKey: primaryKey,
        subKey: subKey,
        forceRefresh: forceRefresh);