aboutsummaryrefslogtreecommitdiff
path: root/src/Enmarcha.Backend/Types/ConsolidatedCirculation.cs
blob: 75db22565f70017d13e559a19f044591e26e6380 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
namespace Enmarcha.Backend.Types;

public class ConsolidatedCirculation
{
    public required string Line { get; set; }
    public required string Route { get; set; }

    public ScheduleData? Schedule { get; set; }
    public RealTimeData? RealTime { get; set; }
    public Position? CurrentPosition { get; set; }
    public int? StopShapeIndex { get; set; }
    public bool IsPreviousTrip { get; set; }
    public string? PreviousTripShapeId { get; set; }
    public string[] NextStreets { get; set; } = [];
}

public class RealTimeData
{
    public required int Minutes { get; set; }
    public required int Distance { get; set; }
}

public class ScheduleData
{
    public bool Running { get; set; }
    public required int Minutes { get; set; }
    public required string ServiceId { get; set; }
    public required string TripId { get; set; }
    public string? ShapeId { get; set; }
}

public class Position
{
    public required double Latitude { get; set; }
    public required double Longitude { get; set; }
    public int? Bearing { get; set; }
    public int ShapeIndex { get; set; }
}

public class Epsg25829
{
    public double X { get; set; }
    public double Y { get; set; }
}

public class Shape
{
    public List<Epsg25829> Points { get; set; } = [];
}