Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Compostion,Association and aggregation in java

 
anish jain
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to know how to implement Compostion,Aggregation and Association in Java.

I searched many time but never got any satisfactroy answer
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please, SearchFirst
 
john sal
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Stephan van Hulst wrote:Please read the message following this post


Composition:
Aggregation:

In the case of composition, the Engine is completely encapsulated by the Car. There is no way for the outside world to get a reference to the Engine. The Engine lives and dies with the car. With aggregation, the Car also performs its functions through an Engine, but the Engine is not always an internal part of the Car. Engines may be swapped, or even completely removed. Not only that, but the outside world can still have a reference to the Engine, and tinker with it regardless of whether it's in the Car.
 
Stephan van Hulst
Bartender
Pie
Posts: 5811
61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
John, I appreciate that you're helping other users out; but when you cite material written by someone else, please provide a link to the source.
 
john sal
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sure I will take care of it in future.

Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic