Hi Petr,
Thanks for the comments!
TransferTest.cpp:75/80
I think you can get rid of the local variable packetProcessors since it’s used only as a paramter of the Transfer ctor.
In general yes, but how do you add three elements to the QList before passing the list to the ctor? Using += could do the trick but the result would not more readable.
Choker.h:71
The Choker:: qualifier is superfluous there.
Yes, it is! I had to add it nevertheless because Choker::Sessions had to be qualified for the generated Driver class to compile. The patched moc parses all functions with their return and parameter types but cannot know whether the name has to be additionally qualified or not. That’s why I had to “help” it.
I was thinking, shouldn’t we unify the TransferSession parameter position? But maybe there is a reason for that it’s not unified…
Hm, I think yes, that makes sense.
Q_ASSERT (list.size() != 0); // To ensure we won’t end on a floating point exception in the division below
qint64 sum = std::accomulate (list.begin(), list.end(), 0); // Standard algorithms should be more clearer than raw loops
return sum / list.size();
Great!
So, what should I focus on now? Maybe implementing the TrackerManager, or do a detailed review of the new code/design/todos, or something else - what do you think?
I think starting with TrackerManager’s implementation would be better. This way we’ll have more going in parallel. After we’ve both dome some more progress we could switch and do detailed reviews of each other’s code.
Regards,
Peter
