dispose method

void dispose()

Disposes the plugin, stops all streams, and stops all listeners. Once disposed, this plugin cannot be used again until the application fully restarts.

Implementation

void dispose() {
  _overriddenLocation = null;
  _overriddenLocationPermission = null;

  _locationSubscription?.cancel();
  _locationSubscription = null;

  _locationStreamController?.close();
  _locationStreamController = null;

  _testController = null;
}