using Newtonsoft.Json;

namespace Lada.Framework.DTO.Results.GoogleMap
{
    public class GoogleMapsApiResponse
    {
        public string Status { get; set; }
        public RouteInfo[] Routes { get; set; }
    }

    public class DistanceMatrixResponse
    {
        [JsonProperty("destination_addresses")]
        public List<string> DestinationAddresses { get; set; }

        [JsonProperty("origin_addresses")]
        public List<string> OriginAddresses { get; set; }

        [JsonProperty("rows")]
        public List<Row> Rows { get; set; }

        [JsonProperty("status")]
        public string Status { get; set; }
    }

    public class Row
    {
        [JsonProperty("elements")]
        public List<Element> Elements { get; set; }
    }

    public class Element
    {
        [JsonProperty("distance")]
        public ValueText Distance { get; set; }

        [JsonProperty("duration")]
        public ValueText Duration { get; set; }

        [JsonProperty("status")]
        public string Status { get; set; }
    }

    public class ValueText
    {
        [JsonProperty("text")]
        public string Text { get; set; }

        [JsonProperty("value")]
        public int Value { get; set; }
    }

}
