onLocationChange method
Implementation
@override
StreamSubscription<dynamic> onLocationChange(
LocationChangeListener callback) {
return eventChannel.receiveBroadcastStream().listen((event) {
Map<String, dynamic> data =
(event as Map<Object?, Object?>).cast<String, dynamic>();
Location location = Location.fromJson(data);
callback(location);
});
}