fromGooglePrediction method

void fromGooglePrediction(
  1. Prediction prediction
)

Implementation

void fromGooglePrediction(Prediction prediction) {
  final location = this;
  location.googlePlaceId = prediction.placeId;

  location.description = prediction.structuredFormatting!.mainText;
  location.type = prediction.structuredFormatting!.secondaryText;
}