stopBackgroundService method

  1. @override
Future<bool> stopBackgroundService()
override

Stop background service

Implementation

@override
Future<bool> stopBackgroundService() async {
  if (!_initialized) {
    throw MCPException('Web platform is not initialized');
  }

  if (_backgroundService == null) {
    _logger.fine('Background service is not available');
    return false;
  }

  return await _backgroundService!.stop();
}