Beispiel #1
0
        public void GetTrafficFlowSegment()
        {
            var am  = new AzureMapsToolkit.AzureMapsServices(_KEY);
            var req = new TrafficFlowSegmentRequest
            {
                Query = "52.41072,4.84239",
                Style = TrafficFlowSegmentStyle.Absolute,
                Zoom  = 10
            };

            var r = am.GetTrafficFlowSegment(req).Result;

            Assert.Null(r.Error);
        }
Beispiel #2
0
        public async Task GetTrafficFlowSegment()
        {
            var am  = new AzureMapsToolkit.AzureMapsServices(_KEY);
            var req = new TrafficFlowSegmentRequest
            {
                //Query = "52.41072,4.84239",
                Query = "62.40948,17.23301",
                Style = TrafficFlowSegmentStyle.Absolute,
                Zoom  = 10
            };

            var r = await am.GetTrafficFlowSegment(req);

            Assert.Null(r.Error);
        }
Beispiel #3
0
        /// <summary>
        /// This service provides information about the speeds and travel times of the road fragment closest to the given coordinates. It is designed to work alongside the Flow layer of the Render Service to support clickable flow data visualizations. With this API, the client side can connect any place in the map with flow data on the closest road and present it to the user.
        /// </summary>
        /// <param name="req"></param>
        /// <returns></returns>
        public virtual async Task <Response <TrafficFlowSegmentResult> > GetTrafficFlowSegment(TrafficFlowSegmentRequest req)
        {
            var res = await ExecuteRequest <TrafficFlowSegmentResult, TrafficFlowSegmentRequest>
                          ("https://atlas.microsoft.com/traffic/flow/segment/json", req);

            return(res);
        }