The MDP protocol has ordered datalines, that means that every line has to contain a value for every dataline and they have to be in the same order as they were defined by the header.
On the other hand the CMDP protocol (see #30) does not necessary contain a value in every data message for every dataline. Also these values do not need to be ordered. This is possible because the dataline are referenced with an ID in this protocol (Y0, Y1...etc).
To be able to handle both of them effectively with the DataLine and Diagram classes we need to design and implement a class that is similar to the OrderedDict in Python.
Description
The MDP protocol has ordered datalines, that means that every line has to contain a value for every dataline and they have to be in the same order as they were defined by the header.
On the other hand the CMDP protocol (see #30) does not necessary contain a value in every data message for every dataline. Also these values do not need to be ordered. This is possible because the dataline are referenced with an ID in this protocol (Y0, Y1...etc).
To be able to handle both of them effectively with the DataLine and Diagram classes we need to design and implement a class that is similar to the OrderedDict in Python.
See description for this container here: https://docs.python.org/3.8/library/collections.html#collections.OrderedDict https://www.geeksforgeeks.org/ordereddict-in-python/
TODO
Optionally it could be a standalone repo that is added as a Git submodule to the project