Difficulty: Easy
Correct Answer: Aggregation
Explanation:
Introduction / Context:Composition and aggregation both model whole part relationships, but they differ in strength and lifecycle semantics. Understanding the distinction helps model ownership, lifetime, and deletion cascading correctly.
Given Data / Assumptions:
Concept / Approach:Composition is a stronger form of aggregation because it implies strong ownership and coincident lifetimes. If the composite (whole) is destroyed, its components (parts) are destroyed with it. Aggregation, by contrast, indicates a weaker association where parts may exist independently.
Step-by-Step Solution:
Map relationships: aggregation implies sharing, composition implies exclusive ownership.Examine lifecycle: in composition, parts depend on the whole for existence.Conclude that composition is the stronger form of aggregation.Verification / Alternative check:Modeling tools and textbooks present composition as a strict variant of aggregation with stronger constraints on lifetime and containment.
Why Other Options Are Wrong:
Common Pitfalls:Overusing composition where aggregation suffices; confusing visual notation; assuming composition always implies physical containment rather than logical ownership.
Final Answer:Aggregation
Discussion & Comments