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