Skip to content

Move geometry reception functionality to mixin class

David Hammer requested to merge geometry-receiver-mixin into sfx-hitfinder-and-geometry

Improving code reuse / reducing boilerplate has been a topic recently. So far, I've avoided multiple inheritance (afraid of ending up like calPy and friends), though - if we stick to reasonably orthogonal mixins - it would provide a simpler way to couple static expectedParameters with some runtime functionality.

Subscribing to geometry is a fairly trivial setup, but it's nicely separatable and as it's used in multiple device classes, we get rid of some duplication. Do we like this mixin style? If yes, maybe some other functionality (warning system / CalCat interaction) could follow similar pattern - that could start to cut down on boilerplate in concrete correction classes.

Merge request reports