The Artima Developer Community
Sponsored Link

Re: Composition and Aggregation



This page contains an archived post to the Design Forum (formerly called the Flexible Java Forum) made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.


Re: Composition and Aggregation

Posted by John Caron on 24 Nov 1998, 4:27 PM

paraphrased from UML Distilled:

Aggregation is the "part-whole" relationship.

Composition is a stronger form of aggregation: the "part" can only be contained by one "whole", and when the "whole" is deleted, all the parts are deleted. In aggregation, the part may live independently from their containing object.

I can't say I particularly like the words chosen to make this distinction. Nor am I sure why the distinction is important enough to make us all confused as to which is which.


Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us