uri method

String uri(
  1. double latitude,
  2. double longitude
)

Implementation

String uri(double latitude, double longitude) {
  switch (this) {
    case NavApp.waze:
      return Platform.isAndroid
          ? 'https://waze.com/ul?ll=$latitude,$longitude&navigate=yes'
          : 'waze://?ll=$latitude,$longitude&navigate=yes';
    case NavApp.gmaps:
      return Platform.isAndroid
          ? 'https://maps.google.com/maps?daddr=$latitude,$longitude'
          : 'comgooglemaps://?q=$latitude,$longitude';
    case NavApp.appleMaps:
      return 'https://maps.apple.com/?saddr=Current%20Location&daddr=$latitude,$longitude';
  }
}