From 38434b0d864ade6d784285ee6fdaafd75bfca70c Mon Sep 17 00:00:00 2001 From: Jannik Beyerstedt Date: Sat, 15 Aug 2026 21:08:50 +0200 Subject: [PATCH] map: Extract max end time --- src/applogic/v2x/map.rs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/applogic/v2x/map.rs b/src/applogic/v2x/map.rs index bac8a69..d7e2195 100644 --- a/src/applogic/v2x/map.rs +++ b/src/applogic/v2x/map.rs @@ -173,6 +173,12 @@ impl Intersection { { sig_grp.likely_time = Some(likely.to_datetime_from_moy(moy, year)); } + if let Some(max) = &timing.max_end_time + && !max.is_out_of_range() + && !max.is_unknown() + { + sig_grp.max_end_time = Some(max.to_datetime_from_moy(moy, year)); + } } } } else { @@ -223,6 +229,7 @@ impl Intersection { target_lanes, phase: None, min_end_time: None, + max_end_time: None, likely_time: None, } }) @@ -410,7 +417,7 @@ pub struct SignalGroup { /// current signal phase phase: Option, min_end_time: Option>, - // max_end_time: Option>, + max_end_time: Option>, likely_time: Option>, } @@ -443,6 +450,9 @@ impl SignalGroup { pub fn likely_time(&self) -> Option> { self.likely_time } + pub fn max_end_time(&self) -> Option> { + self.max_end_time + } pub fn phase_to_str(&self) -> Option { self.phase.map(|v| {