pub struct PisRoute {
pub line_code: (u32, u32),
pub stop_codes: Vec<u32>,
pub special_char_code: Option<u32>,
pub routing_code: Option<u32>,
pub text: Option<String>,
pub termini: Vec<PisRouteTerminus>,
pub following_line_code: Option<(u32, u32)>,
}Expand description
Datensatz für eine Route im PIS. Jeder Datensatz wird über eine Liniennummer und einen Code innerhalb der Linie identifiziert.
PIS route record identified by line number and in-line route code.
Fields§
§line_code: (u32, u32)Liniennummer und Code innerhalb der Linie zur Zuordnung.
Line number and in-line route code for identification.
stop_codes: Vec<u32>Liste der Codes der Haltestellen, die auf der Route nacheinander angefahren werden, inklusive der Abfahrts- und der Endhaltestelle.
Stop codes visited in order, including departure and destination stops.
special_char_code: Option<u32>Code des Sonderzeichens, das automatisch ausgewählt werden soll, wenn diese Route eingestellt wird. Ob dieser Code überschrieben werden kann, ist abhängig vom Bordrechner.
Special-character code selected automatically when this route is set; overridability depends on the onboard computer.
routing_code: Option<u32>Sind für das Balisensystem/Anforderungen/Weichen individuelle Anmelde-Codes nötig?
Optional routing/signalling code for balise systems, requests, or turnouts.
text: Option<String>Zusätzliches Textfeld ohne fest definierte Bedeutung.
Additional text field with no fixed meaning currently.
termini: Vec<PisRouteTerminus>Im einfachsten Fall ist das Ziel einer Route die letzte Haltestelle. Ab einer bestimmten Haltestelle kann das angezeigte Ziel wechseln oder anders dargestellt werden. Dafür können Termini definiert werden.
Usually the destination is the last stop; termini override the displayed destination from specific stops onward.
following_line_code: Option<(u32, u32)>Linie und Code der automatisch zu wählenden Folgeroute.
Line and code of the route to select automatically next.
Implementations§
Source§impl PisRoute
impl PisRoute
Sourcepub fn new(
line_code: (u32, u32),
stop_codes: Vec<u32>,
special_char_code: Option<u32>,
routing_code: Option<u32>,
text: Option<String>,
termini: Vec<PisRouteTerminus>,
following_line_code: Option<(u32, u32)>,
) -> PisRoute
pub fn new( line_code: (u32, u32), stop_codes: Vec<u32>, special_char_code: Option<u32>, routing_code: Option<u32>, text: Option<String>, termini: Vec<PisRouteTerminus>, following_line_code: Option<(u32, u32)>, ) -> PisRoute
Erstellt einen neuen PIS-Routendatensatz.
Creates a new PIS route record.
Sourcepub fn get_current_direction(
&self,
stop_index: usize,
) -> Option<PisRouteTerminus>
pub fn get_current_direction( &self, stop_index: usize, ) -> Option<PisRouteTerminus>
Gibt das aktive Routenziel ab dem aktuellen Haltestellenindex zurück.
Returns the active route terminus from the current stop index onward.