init static method
Future<void>
init({
- required AndroidNotificationOptions androidNotificationOptions,
- IOSNotificationOptions? iosNotificationOptions,
- ForegroundTaskOptions? foregroundTaskOptions,
- bool? printDevLog,
Initialize the FlutterForegroundTask.
Implementation
static Future<void> init({
required AndroidNotificationOptions androidNotificationOptions,
IOSNotificationOptions? iosNotificationOptions,
ForegroundTaskOptions? foregroundTaskOptions,
bool? printDevLog,
}) async {
_androidNotificationOptions = androidNotificationOptions;
_iosNotificationOptions = iosNotificationOptions ??
_iosNotificationOptions ??
const IOSNotificationOptions();
_foregroundTaskOptions = foregroundTaskOptions ??
_foregroundTaskOptions ??
const ForegroundTaskOptions();
_printDevLog = printDevLog ?? _printDevLog;
}