This commit is contained in:
runette committed 2024-04-22 15:52:51 +01:00
commit e0afef912e
1285 files changed
+83219

No files matched your search

@@ -0,0 +1,38 @@
//-----------------------------------------------------------------------
// <copyright file="Leg.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using System.Collections.Generic;
using Mapbox.Json;
/// <summary>
/// <para>An annotations object contains additional details about each line segment along the route geometry.</para>
/// <para></para>Each entry in an annotations field corresponds to a coordinate along the route geometry.
/// </summary>
public class Annotation
{
[JsonProperty("distance")]
public double[] Distance { get; set; }
[JsonProperty("duration")]
public double[] Duration { get; set; }
[JsonProperty("speed")]
public string[] Speed { get; set; }
[JsonProperty("congestion")]
public string[] Congestion { get; set; }
}
}
@@ -0,0 +1,13 @@
fileFormatVersion: 2
guid: 204896b65f98440449415ca9b9c1d643
timeCreated: 1508343130
licenseType: Pro
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,41 @@
//-----------------------------------------------------------------------
// <copyright file="DirectionsResponse.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions {
using System;
using System.Collections.Generic;
using Mapbox.Json;
/// <summary>
/// Directions response.
/// </summary>
#if !WINDOWS_UWP
// http://stackoverflow.com/a/12903628
[Serializable]
#endif
public class DirectionsResponse {
/// <summary>
/// Gets or sets the routes.
/// </summary>
/// <value>The routes.</value>
[JsonProperty("routes")]
public List<Route> Routes { get; set; }
/// <summary>
/// Gets or sets the waypoints.
/// </summary>
/// <value>The waypoints.</value>
[JsonProperty("waypoints")]
public List<Waypoint> Waypoints { get; set; }
/// <summary>
/// Gets or sets the code.
/// </summary>
/// <value>The code.</value>
[JsonProperty("code")]
public string Code { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: f69de6bfcf63e4d2ab766574bca2caf6
timeCreated: 1491243035
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,55 @@
//-----------------------------------------------------------------------
// <copyright file="Intersection.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using System.Collections.Generic;
using Mapbox.Json;
using Mapbox.Utils;
using Mapbox.Utils.JsonConverters;
/// <summary>
/// An Intersection from a Directions API call.
/// </summary>
public class Intersection
{
/// <summary>
/// Gets or sets the out.
/// </summary>
/// <value>The out.</value>
[JsonProperty("out", Order = 0)]
public int Out { get; set; }
/// <summary>
/// Gets or sets the entry.
/// </summary>
/// <value>The entry.</value>
[JsonProperty("entry", Order = 1)]
public List<bool> Entry { get; set; }
/// <summary>
/// Gets or sets the bearings.
/// </summary>
/// <value>The bearings.</value>
[JsonProperty("bearings", Order = 2)]
public List<int> Bearings { get; set; }
/// <summary>
/// Gets or sets the location.
/// </summary>
/// <value>The location.</value>
[JsonProperty("location", Order = 3)]
[JsonConverter(typeof(LonLatToVector2dConverter))]
public Vector2d Location { get; set; }
/// <summary>
/// Gets or sets the in.
/// </summary>
/// <value>The in.</value>
[JsonProperty("in", Order = 4, NullValueHandling = NullValueHandling.Ignore)]
public int? In { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 38b89d19d5fc44375966036ad1331f3d
timeCreated: 1493218361
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,58 @@
//-----------------------------------------------------------------------
// <copyright file="Leg.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using System.Collections.Generic;
using Mapbox.Json;
/// <summary>
/// A Leg from a Directions API call.
/// </summary>
public class Leg
{
/// <summary>
/// Depending on the steps parameter, either an Array of RouteStep objects (true, default) or an empty array (false)
/// </summary>
/// <value>The steps.</value>
[JsonProperty("steps")]
public List<Step> Steps { get; set; }
/// <summary>
/// Depending on the summary parameter, either a String summarizing the route (true, default) or an empty String (false).
/// </summary>
/// <value>The summary.</value>
[JsonProperty("summary")]
public string Summary { get; set; }
/// <summary>
/// Number indicating the estimated travel time in seconds.
/// </summary>
[JsonProperty("duration")]
public double Duration { get; set; }
/// <summary>
/// Number indicating the distance traveled in meters.
/// </summary>
[JsonProperty("distance")]
public double Distance { get; set; }
/// <summary>
/// An annotations object that contains additional details about each line segment along the route geometry. Each entry in an annotations field corresponds to a coordinate along the route geometry.
/// </summary>
[JsonProperty("annotation")]
public Annotation Annotation { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 7847e2706c04347a19461bd848b5e1bd
timeCreated: 1491243034
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,59 @@
//-----------------------------------------------------------------------
// <copyright file="Maneuver.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using Mapbox.Json;
using Mapbox.Utils;
/// <summary>
/// A Maneuver from a directions API call.
/// </summary>
public class Maneuver
{
/// <summary>
/// Gets or sets the bearing after.
/// </summary>
/// <value>The bearing after.</value>
[JsonProperty("bearing_after")]
public int BearingAfter { get; set; }
/// <summary>
/// Gets or sets the type.
/// </summary>
/// <value>The type.</value>
[JsonProperty("type")]
public string Type { get; set; }
/// <summary>
/// Gets or sets the modifier.
/// </summary>
/// <value>The modifier.</value>
[JsonProperty("modifier")]
public string Modifier { get; set; }
/// <summary>
/// Gets or sets the bearing before.
/// </summary>
/// <value>The bearing before.</value>
[JsonProperty("bearing_before")]
public int BearingBefore { get; set; }
/// <summary>
/// Gets or sets the location.
/// </summary>
/// <value>The location.</value>
[JsonProperty("Location")]
public Vector2d Location { get; set; }
/// <summary>
/// Gets or sets the instruction.
/// </summary>
/// <value>The instruction.</value>
[JsonProperty("instruction")]
public string Instruction { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 41f778a9c28ef4b17ace4d80f89dbc7a
timeCreated: 1493218361
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,61 @@
//-----------------------------------------------------------------------
// <copyright file="Route.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using System.Collections.Generic;
using Mapbox.Json;
using Mapbox.Utils;
using Mapbox.Utils.JsonConverters;
/// <summary>
/// A Route from a Directions API call.
/// </summary>
public class Route
{
/// <summary>
/// Gets or sets the legs.
/// </summary>
/// <value>The legs.</value>
[JsonProperty("legs")]
public List<Leg> Legs { get; set; }
/// <summary>
/// Gets or sets the geometry. Polyline is an array of LatLng's.
/// </summary>
/// <value>The geometry.</value>
[JsonProperty("geometry")]
[JsonConverter(typeof(PolylineToVector2dListConverter))]
public List<Vector2d> Geometry { get; set; }
/// <summary>
/// Gets or sets the duration.
/// </summary>
/// <value>The duration.</value>
[JsonProperty("duration")]
public double Duration { get; set; }
/// <summary>
/// Gets or sets the distance.
/// </summary>
/// <value>The distance.</value>
[JsonProperty("distance")]
public double Distance { get; set; }
/// <summary>
/// Float indicating the weight in units described by 'weight_name'.
/// </summary>
[JsonProperty("weight")]
public float Weight { get; set; }
/// <summary>
/// String indicating which weight was used. The default is routability which is duration based, with additional penalties for less desirable maneuvers.
/// </summary>
[JsonProperty("weight_name")]
public string WeightName { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 67e17dbf44b85417d90ee1b71d9749f3
timeCreated: 1493218361
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,69 @@
//-----------------------------------------------------------------------
// <copyright file="Step.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using System.Collections.Generic;
using Mapbox.Json;
using Mapbox.Utils;
using Mapbox.Utils.JsonConverters;
/// <summary>
/// A step from a Directions API call.
/// </summary>
public class Step
{
/// <summary>
/// Gets or sets the intersections.
/// </summary>
/// <value>The intersections.</value>
[JsonProperty("intersections")]
public List<Intersection> Intersections { get; set; }
/// <summary>
/// Gets or sets the geometry.
/// </summary>
/// <value>The geometry.</value>
[JsonProperty("geometry")]
[JsonConverter(typeof(PolylineToVector2dListConverter))]
public List<Vector2d> Geometry { get; set; }
/// <summary>
/// Gets or sets the maneuver.
/// </summary>
/// <value>The maneuver.</value>
[JsonProperty("maneuver")]
public Maneuver Maneuver { get; set; }
/// <summary>
/// Gets or sets the duration.
/// </summary>
/// <value>The duration.</value>
[JsonProperty("duration")]
public double Duration { get; set; }
/// <summary>
/// Gets or sets the distance.
/// </summary>
/// <value>The distance.</value>
[JsonProperty("distance")]
public double Distance { get; set; }
/// <summary>
/// Gets or sets the name.
/// </summary>
/// <value>The name.</value>
[JsonProperty("name")]
public string Name { get; set; }
/// <summary>
/// Gets or sets the mode.
/// </summary>
/// <value>The mode.</value>
[JsonProperty("mode")]
public string Mode { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: cb67b81b6de1f41fca077297633b5a7d
timeCreated: 1493218361
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
@@ -0,0 +1,33 @@
//-----------------------------------------------------------------------
// <copyright file="Waypoint.cs" company="Mapbox">
// Copyright (c) 2016 Mapbox. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace Mapbox.Directions
{
using Mapbox.Json;
using Mapbox.Utils;
using Mapbox.Utils.JsonConverters;
/// <summary>
/// A Waypoint from a Directions API call.
/// </summary>
public class Waypoint
{
/// <summary>
/// Gets or sets the name.
/// </summary>
/// <value>The name.</value>
[JsonProperty("name")]
public string Name { get; set; }
/// <summary>
/// Gets or sets the location.
/// </summary>
/// <value>The location.</value>
[JsonProperty("location")]
[JsonConverter(typeof(LonLatToVector2dConverter))]
public Vector2d Location { get; set; }
}
}
@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 813ff4647909949fdbd67f232221cab3
timeCreated: 1493218361
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: