startForegroundService method

Future<void> startForegroundService(
  1. FlutterAndroidIntent intent, {
  2. bool debug = false,
})

Implementation

Future<void> startForegroundService(
  FlutterAndroidIntent intent, {
  bool debug = false,
}) async {
  await _shell.exec([
    'am',
    'start-foreground-service',
    ...intent.asArguments(),
  ], debug: debug);
}