diff options
author | Daniel Schadt <kingdread@gmx.de> | 2020-10-01 16:44:59 +0200 |
---|---|---|
committer | Daniel Schadt <kingdread@gmx.de> | 2020-10-01 16:44:59 +0200 |
commit | 62249e950c0c5dee0b09b962842543fd60c9ccb4 (patch) | |
tree | 337312ec128010d6ea6a04df51f7a0f10acd6061 /src/statistics/mechanics.rs | |
parent | fa3f8e5ce231a5844e59f0d5e1081b5c6f8274c8 (diff) | |
download | evtclib-62249e950c0c5dee0b09b962842543fd60c9ccb4.tar.gz evtclib-62249e950c0c5dee0b09b962842543fd60c9ccb4.tar.bz2 evtclib-62249e950c0c5dee0b09b962842543fd60c9ccb4.zip |
move Agent definition to a separate file
Just like with Event, we now have Agent defined in its own submodule.
The amount of code that it entailed was a lot, so it made sense to split
it off, especially with the deserialization being another big chunk of
Agent related code in lib.rs
The main issue was that the processing submodule accessed private fields
of the Agent struct, which is now no longer possible (since processing
is no longer a submodule of the module in which Agent is defined).
Therefore, some simple crate-public setters for those fields have been
added. Those setters are not public because we do not want outside
crates to mess with the innards of Agent (yet).
Although with (de)serialization being a thing, we need to ensure that we
can handle nonsensical values anyway, since we can no longer guarantee
that we have full control over all of the values, even without setters.
Diffstat (limited to 'src/statistics/mechanics.rs')
0 files changed, 0 insertions, 0 deletions