BikeInCity.Utils.LocationsConverter.Convert C# (CSharp) Метод

Convert() публичный Метод

Converts a value.
public Convert ( object value, Type targetType, object parameter, CultureInfo culture ) : object
value object The value produced by the binding source.
targetType System.Type The type of the binding target property.
parameter object The converter parameter to use.
culture System.Globalization.CultureInfo The culture to use in the converter.
Результат object
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            List<Coordinate> coordinates = value as List<Coordinate>;
              LocationCollection collection = new LocationCollection();
              foreach (Coordinate coord in coordinates)
              {
            collection.Add(new GeoCoordinate(coord.Latitude,coord.Longitude));
              }
              return collection;
        }
LocationsConverter