resolveIOSImplementation method
Returns the underlying platform-specific implementation of given generic type T, which must be a concrete subclass of FlutterLocalNotificationsPlatform.
Implementation
Future<bool> resolveIOSImplementation({
bool alert = true,
bool badge = true,
bool sound = true,
}) async {
assert(_init!, 'ScheduleNotifications: Failed to call init() first!');
if (!_init!) {
return false;
}
IOSFlutterLocalNotificationsPlugin? implementation;
try {
implementation = _flutterLocalNotificationsPlugin
?.resolvePlatformSpecificImplementation<
IOSFlutterLocalNotificationsPlugin>();
} catch (ex) {
getError(ex);
}
var request = implementation != null;
if (request) {
request = await (implementation!.requestPermissions(
alert: alert,
badge: badge,
sound: sound,
) as Future<bool>);
}
return request;
}