ModelSource.network constructor

ModelSource.network(
  1. String url, {
  2. String? authToken,
  3. bool? foreground,
})

Creates a network-based source (HTTPS/HTTP)

foreground controls Android foreground service:

  • null (default): NO foreground service — this branch configures no notification, and the platform needs one before it starts the service
  • true: always use foreground (shows notification)
  • false: never use foreground

Implementation

factory ModelSource.network(
  String url, {
  String? authToken,
  bool? foreground,
}) = NetworkSource;