enqueue static method
Future<int>
enqueue(
{ - required String downloadUrl,
- required String downloadPath,
- required String fileName,
- String description = "Downloading in progress",
- bool allowScanningByMediaScanner = true,
- int notificationVisibility = NotificationVisibility.VISIBILITY_VISIBLE_NOTIFY_COMPLETED,
})
Implementation
static Future<int> enqueue({
required String downloadUrl,
required String downloadPath,
required String fileName,
String description = "Downloading in progress",
Map<String, String>? headers,
bool allowScanningByMediaScanner = true,
int notificationVisibility =
NotificationVisibility.VISIBILITY_VISIBLE_NOTIFY_COMPLETED,
}) async {
return await _channel.invokeMethod("enqueue", {
"downloadUrl": downloadUrl,
"downloadPath": downloadPath,
"description": description,
"fileName": fileName,
"headers": headers,
"allow_scanning_by_media_scanner": allowScanningByMediaScanner,
"notification_visibility": notificationVisibility,
});
}