Added Provisional Chart Models
This commit is contained in:
parent
6887d33fe2
commit
b2d4b52d6e
36
Models/ChartModel.cs
Normal file
36
Models/ChartModel.cs
Normal file
@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using EFB.Models.JSON;
|
||||
|
||||
namespace EFB.Models
|
||||
{
|
||||
public class ChartModel
|
||||
{
|
||||
public Chart[] General { get; set; }
|
||||
public Chart[] TextualData { get; set; }
|
||||
public Chart[] GroundLayout { get; set; }
|
||||
public Chart[] SID { get; set; }
|
||||
public Chart[] STAR { get; set; }
|
||||
public Chart[] Approach { get; set; }
|
||||
public Chart[] Transition { get; set; }
|
||||
public Chart[] PilotBriefing { get; set; }
|
||||
}
|
||||
|
||||
public class Pinned
|
||||
{
|
||||
public Chart[] Charts { get; set; }
|
||||
}
|
||||
|
||||
// public class Chart *Found in Models/JSON*
|
||||
// {
|
||||
// public string Name { get; set; }
|
||||
// public string Identifier { get; set; }
|
||||
// public int TypeCode { get; set; }
|
||||
// public string Type { get; set; }
|
||||
// public string Runway { get; set; }
|
||||
// public string PseudoURL { get; set; }
|
||||
// public string URL { get; set; }
|
||||
// }
|
||||
}
|
64
Models/JSON/ChartResponse.cs
Normal file
64
Models/JSON/ChartResponse.cs
Normal file
@ -0,0 +1,64 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace EFB.Models.JSON
|
||||
{
|
||||
public class ChartResponse
|
||||
{
|
||||
[JsonProperty("status")]
|
||||
public string Status { get; set; }
|
||||
[JsonProperty("charts")]
|
||||
public ChartList Response { get; set; }
|
||||
}
|
||||
|
||||
public class ChartList
|
||||
{
|
||||
[JsonProperty("0")]
|
||||
public ChartsCollection General { get; set; }
|
||||
[JsonProperty("1")]
|
||||
public ChartsCollection TextualData { get; set; }
|
||||
[JsonProperty("2")]
|
||||
public ChartsCollection GroundLayout { get; set; }
|
||||
[JsonProperty("6")]
|
||||
public ChartsCollection SID { get; set; }
|
||||
[JsonProperty("7")]
|
||||
public ChartsCollection STAR { get; set; }
|
||||
[JsonProperty("8")]
|
||||
public ChartsCollection Approach { get; set; }
|
||||
[JsonProperty("9")]
|
||||
public ChartsCollection Transition { get; set; }
|
||||
[JsonProperty("99")]
|
||||
public ChartsCollection PilotBriefing { get; set; }
|
||||
}
|
||||
|
||||
public class ChartsCollection
|
||||
{
|
||||
[JsonProperty("group_name")]
|
||||
public string Category { get; set; }
|
||||
[JsonProperty("charts")]
|
||||
public Chart[] Charts { get; set; }
|
||||
}
|
||||
|
||||
public class Chart
|
||||
{
|
||||
[JsonProperty("name")]
|
||||
public string Name { get; set; }
|
||||
[JsonProperty("identifier")]
|
||||
public string Identifier { get; set; }
|
||||
[JsonProperty("type_code")]
|
||||
public int TypeCode { get; set; }
|
||||
[JsonProperty("type")]
|
||||
public string Type { get; set; }
|
||||
[JsonProperty("runway")]
|
||||
public string Runway { get; set; }
|
||||
[JsonProperty("pseudo_url")]
|
||||
public string PseudoURL { get; set; }
|
||||
[JsonProperty("url")]
|
||||
public string URL { get; set; }
|
||||
}
|
||||
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user