• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Doubt regarding Cade's class diagram

 
Samuel Pessorrusso
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

In the Cade's class diagram, we have "maganer" classes like OrderProcessor and AccountManager. These classes have just one dependency and that is a little bit strange. For example, the AccountManager class has dependency only with Customer, but what about Address and CreditCard? Shouldn't AccountManager class had dependency with these classes (Address and CreditCard)?
Moreover, the OrderProcessor class has dependency just with Order, shouldn't OrderProcessor has dependency with LineItem, Product and Payment?

Regards
Samuel
 
Vinay Singh
Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Samuel
The relationship is of dependeny but it actually manager class 'uses' these objects. Since Address and credit card are linked to customer therefore AccountManager class will internally use these objects. As such it does not have a direct relationship with these objects.
 
Dan Drillich
Ranch Hand
Posts: 1183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Samuel,

Let's keep in mind that Customer was amplified from the BDM to include the Address, CreditCard and the ShoppingCart classes. The same is with the Order which was amplified to have Payment and LineItem. So conceptually, Customer and Order include the other classes.

Regards,
Dan
 
Samuel Pessorrusso
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok, that will simplify my class diagram
Just to be sure... Imagine that we had a �PaymentMgr� which �creates� the �Payment�, if even if this �PaymentMgr� needs to validate the �CreditCard� it won�t have any dependency with it drew in the class diagram, right?

Thanks for you reply, guys!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic