1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2025-06-19 08:15:16 +00:00

Ready to pre-configure independent notifications service

This commit is contained in:
2021-04-13 17:56:55 +02:00
parent 7e9a594bae
commit 1400bbbeb7
6 changed files with 73 additions and 6 deletions

View File

@ -0,0 +1,18 @@
import 'package:flutter/services.dart';
/// Independent push notifications helper
///
/// @author Pierre Hubert
class IndependentPushNotificationsHelper {
static const platform = const MethodChannel(
"org.communiquons.comunic/independent-push-notifications-service");
/// Call this method to prepare the application for background refresh by
/// requesting appropriate permissions, configuring battery optimization...
///
/// Throws an Exception in case of failure
static Future<void> preConfigure() async {
await platform.invokeMethod("preConfigure");
}
}