Turn batch_t into a class
Description
Turn batch_t into a class. Add consistency checks and fix some issues.
News snippet
Turn batch_t into a class.
Checklist
-
I have checked that my code follows the Octopus coding standards -
I have added tests for all the new features added in this request.