Reading from different posts from this site what I understood
that association is more stronger than dependency.
ClassA has association with ClassB -- if ClassB is instantiated by ClassA.
ClassA has dependency with ClassB -- if ClassB is passed as parameter in
a method or returned as parameter from a method call.
Now consider a case:
Client is using three classes
atabase, Model, Element.
Client instantiates Database object, using the Database object gets
reference of Model object and after that calls method on Model object
to get Element. On the Element object client further calls method to
get the element inside the Element object.
In this case, I think relationship should be:
Client ---->(Association)-->Database
Client ---->(Dependency)--->Model
Client---->(Dependency)--->Element
But, I am reading a book, in this book all relationships has been shown
as association from the client.
Client ---->(Association)-->Database
Client ---->(Association)--->Model
Client---->(Association)--->Element
I would appreciate for any input.
Thanks