setLocation method
Implementation
Future<void> setLocation(AddressId addressId, Address address) async {
if (addressId == AddressId.origin) {
_origin = address;
_originController.text = address.reference ?? '';
} else if (addressId == AddressId.destination) {
_destination = address;
_destinationController.text = address.reference ?? '';
} else if (addressId == AddressId.waypoint) {
addWaypoint(address);
}
notifyListeners();
}