I would like to ask for a reccomended solution for this: We have a list of Competitions. Each competition has defined fee that a participatior has to pay We have Participators I have to know has a Participator that is on a Competition paid the fee or not. I am thinking about 2 solutions and the thing is it has to be the most appropriate solution in Domain Driven Design. First is to create a Dictionary in Competition instead of a List, the dictionary would have be of type <Participator, bool>. The secont is perhaps create a different class that has 2 fields, a participator and feePaid. And in Competiton I would have a list of object of that new class.
Thank you
The way I would handle this is to have Competitions, Participants, and Registrations. A Participant would register for a Competition, creating a Registration. A Registration would consist of the Competition id, Participant id, a flag indicating whether the fee was paid or not, and any other registration-specific data (like the date of registration). This would be modeled in the database as a ‘join table’ (with the additional data). On the app side, a Participant would have a list of Registrations, each Registration would have an associated Participant and a Competition. Likewise, each Competition would have a list of Registrations.