INNER CODE UNIT · Dart

AuthCredentials

dreautall/waterfly-iii · lib/auth.dart:153

class AuthCredentials {
  const AuthCredentials({this.host, this.apiKey, this.customHeadersRaw});

  final String? host;
  final String? apiKey;
  final String? customHeadersRaw;
}

http.Client get httpClient => Platform.isAndroid
    ? CronetClient.fromCronetEngine(
        CronetEngine.build(cacheMode: .memory, cacheMaxSize: 2 * 1024 * 1024),
        closeEngine: false,
      )
    : Platform.isIOS
    ? CupertinoClient.fromSessionConfiguration(
        URLSessionConfiguration.ephemeralSessionConfiguration()
          ..cache = URLCache.withCapacity(memoryCapacity: 2 * 1024 * 1024),
      )

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…