locationStream property

Stream<LocationDto> get locationStream

A stream of location data updates. Call start before using this stream.

Implementation

Stream<LocationDto> get locationStream {
  if (_locationStream == null) {
    Stream<dynamic> dataStream = _port.asBroadcastStream();
    _locationStream = dataStream
        .where((event) => event != null)
        .map((location) => location as LocationDto);
  }
  return _locationStream!;
}