I'm trying to write a model of a manufacturing factory. There are feedstocks, composants and finished products. So far I've got roughly this:
As you can see, I would like to find a possibility to define a getType method with a "generic" (not sure if I use the word the right way) return type which should be an enum in the PartInterface. But my implementations of enums FeedstockType and ComponentType have no relation to enum PartType. What can I do?