namespace Enmarcha.Backend.Types.Planner; public class RoutePlan { public List Itineraries { get; set; } = new(); public long? TimeOffsetSeconds { get; set; } } public class Itinerary { public double DurationSeconds { get; set; } public DateTime StartTime { get; set; } public DateTime EndTime { get; set; } public double WalkDistanceMeters { get; set; } public double WalkTimeSeconds { get; set; } public double TransitTimeSeconds { get; set; } public double WaitingTimeSeconds { get; set; } public List Legs { get; set; } = []; public decimal? CashFare { get; set; } public bool? CashFareIsTotal { get; set; } public decimal? CardFare { get; set; } public bool? CardFareIsTotal { get; set; } } public class Leg { public string? Mode { get; set; } // WALK, BUS, etc. public string? FeedId { get; set; } public string? RouteId { get; set; } public string? TripId { get; set; } public string? RouteName { get; set; } public string? RouteShortName { get; set; } public string? RouteLongName { get; set; } public string? Headsign { get; set; } public string? AgencyName { get; set; } public string? RouteColor { get; set; } public string? RouteTextColor { get; set; } public PlannerPlace? From { get; set; } public PlannerPlace? To { get; set; } public DateTime StartTime { get; set; } public DateTime EndTime { get; set; } public double DistanceMeters { get; set; } // GeoJSON LineString geometry public PlannerGeometry? Geometry { get; set; } public List Steps { get; set; } = new(); public List IntermediateStops { get; set; } = new(); } public class PlannerPlace { public string? Name { get; set; } public double Lat { get; set; } public double Lon { get; set; } public string? StopId { get; set; } public string? StopCode { get; set; } public string? ZoneId { get; set; } } public class PlannerGeometry { public string Type { get; set; } = "LineString"; public List> Coordinates { get; set; } = new(); // [[lon, lat], ...] } public class Step { public double DistanceMeters { get; set; } public string? RelativeDirection { get; set; } public string? AbsoluteDirection { get; set; } public string? StreetName { get; set; } public double Lat { get; set; } public double Lon { get; set; } } // For Autocomplete/Reverse public class PlannerSearchResult { public string? Name { get; set; } public string? Label { get; set; } public double Lat { get; set; } public double Lon { get; set; } public string? Layer { get; set; } public string? StopId { get; set; } public string? StopCode { get; set; } }