Reworked classes with relationships