func parseLocationType(locationType string, r *maps.GeocodingRequest) { if locationType != "" { for _, l := range strings.Split(locationType, "|") { switch l { case "ROOFTOP": r.LocationType = append(r.LocationType, maps.GeocodeAccuracyRooftop) case "RANGE_INTERPOLATED": r.LocationType = append(r.LocationType, maps.GeocodeAccuracyRangeInterpolated) case "GEOMETRIC_CENTER": r.LocationType = append(r.LocationType, maps.GeocodeAccuracyGeometricCenter) case "APPROXIMATE": r.LocationType = append(r.LocationType, maps.GeocodeAccuracyApproximate) } } } }