Once I had decided on which classes I would have, I printed and cut them out so that each class was on a small paper rectangle. Then I could move them around while working out the relationships between them.
Multiplicities
There are zero or more bikes on the bike list but there is only one bike list.
A hire transaction must have one and only one bike associated with it, but a bike has either zero (not currently hired) or one (currently hired) transaction associated with it.
A customer hires zero or more bikes (multiple hires possible), but a bike has either one (hired) or zero (not hired) customers associated with it.
A customer is associated with zero or more hire transactions (multiple hires possible) but a hire transaction may only have one customer associated with it.
There are zero or more customers on the customer list but there is only one customer list.

No comments:
Post a Comment