crc cards collaborators

316 views Asked by At

Say I have three classes: User, Address and OrderProduct.

User has fields such as name, phone number and address where address is an instance of Address.

If OrderProduct, a class which handles ordering of products, needs the address stored in User, would I just list User as a collaborator or would I need to include the Address class as a collaborator because User class contains that?

1

There are 1 answers

0
vainolo On

Just the user, because it needs it to get the address. The address itself is just data.