-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: consecutiveTime is misleading for unordered trainruns #319
Comments
To understand how traversing the trainrun works, please also take a look at this figure: More information can be found at https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend/blob/main/documentation/DATA_MODEL.md#data-model The TrainrunIterator operates over a structure that can be conceptualized as an undirected acyclic graph (DAG), where each trainrun is a connected component. Structure
Traversal
The TrainrunIterator can effectively traverse through the trainrun sections by leveraging the source and target nodes of each section. This approach removes the need to explicitly define a direction and uses the inherent structure of the trainrun sections and nodes to guide the traversal. By managing transitions within nodes and ensuring each section is visited once, the iterator can navigate through the entire trainrun efficiently. |
TrainrunIteratorThe TrainrunIterator is a concept aimed at iterating through the sections of a trainrun, similar to how one navigates through the edges of a graph. Here is a detailed description of how this iterator works and how it can be used: Structure of the Trainrun
Traversal Logic
Example Application
Detailed Steps
SummaryThe TrainrunIterator enables structured traversal through the sections of a trainrun by using both a node ID and a specific trainrun section as a starting point. This increases the precision and flexibility of the traversal. By utilizing the source and target nodes of each section and following transitions within the nodes, the iterator can efficiently navigate through the entire trainrun. This method is particularly useful for traversing complex trainrun paths and ensuring that the traversal logic is correctly understood and applied both forwards and backwards. If functionality should be initiated by providing a port ID, this could be a further extension allowing a start directly from a specific port. However, this functionality is not yet implemented. |
Closing this since I had misunderstood consecutiveTime: it makes sense to start from 57 here. |
Preflight Checklist
Bug type
Functionality
Which version are you using
2.8.0
Operating system
No response
Browser / Browser version
No response
Input mode
None
Additional settings
No response
What happened?
Describe in detail the issue you are having.
What did you expect to happen? What happened instead? What would you like to see changed?
Is the issue related to a specific component?
Steps to reproduce the issue
Relevant log output
The text was updated successfully, but these errors were encountered: