Example #1
0
        /// <summary>
        /// Get Avoidance Zone list
        /// </summary>
        public void GetAvoidanceZones()
        {
            // Create the manager with the api key
            Route4MeManager route4Me = new Route4MeManager(c_ApiKey);

            AvoidanceZoneQuery avoidanceZoneQuery = new AvoidanceZoneQuery()
            {
            };

            // Run the query
            string errorString;

            AvoidanceZone[] avoidanceZones = route4Me.GetAvoidanceZones(avoidanceZoneQuery, out errorString);

            Console.WriteLine("");

            if (avoidanceZones != null)
            {
                Console.WriteLine("GetAvoidanceZones executed successfully, {0} zones returned", avoidanceZones.Length);
            }
            else
            {
                Console.WriteLine("GetAvoidanceZones error: {0}", errorString);
            }
        }
        /// <summary>
        /// Get Avoidance Zone list
        /// </summary>
        public void GetAvoidanceZones()
        {
            // Create the manager with the api key
              Route4MeManager route4Me = new Route4MeManager(c_ApiKey);

              AvoidanceZoneQuery avoidanceZoneQuery = new AvoidanceZoneQuery()
              {

              };

              // Run the query
              string errorString;
              AvoidanceZone[] avoidanceZones = route4Me.GetAvoidanceZones(avoidanceZoneQuery, out errorString);

              Console.WriteLine("");

              if (avoidanceZones != null)
              {
            Console.WriteLine("GetAvoidanceZones executed successfully, {0} zones returned", avoidanceZones.Length);
              }
              else
              {
            Console.WriteLine("GetAvoidanceZones error: {0}", errorString);
              }
        }
Example #3
0
        /// <summary>
        /// Get Avoidance Zone list
        /// </summary>
        public void GetAvoidanceZones()
        {
            // Create the manager with the api key
            var route4Me = new Route4MeManager(ActualApiKey);

            var avoidanceZoneQuery = new AvoidanceZoneQuery()
            {
            };

            // Run the query
            AvoidanceZone[] avoidanceZones = route4Me.GetAvoidanceZones(
                avoidanceZoneQuery,
                out string errorString);

            Console.WriteLine("");

            Console.WriteLine(
                avoidanceZones != null
                ? String.Format("GetAvoidanceZones executed successfully, {0} zones returned", avoidanceZones.Length)
                : String.Format("GetAvoidanceZones error: {0}", errorString)
                );
        }