title: Aggregation and Composition in Java Code
body: <p>As the Aggregation and Composition is related Association or we can say it gives the understanding of relationship between object or anything else.</p>
  
  <p>I posted this question because i asked one question in Interview that what is the Composition and Aggregation.</p>
  
  <p>So as per my understanding i given my idea which is as follow.</p>
  
  <p><a href="http://www.coderanch.com/t/522414/java/java/Association-Aggregation-Composition" rel="nofollow noreferrer">http://www.coderanch.com/t/522414/java/java/Association-Aggregation-Composition</a></p>
  
  <p><a href="https://stackoverflow.com/questions/4324704/aggregation-association-and-composition">Aggregation, Association and Composition</a></p>
  
  <p><a href="https://stackoverflow.com/questions/14837826/association-vs-aggregation-vs-composition-in-java">Association vs. Aggregation vs. Composition in Java</a></p>
  
  <p>and also visited much more.</p>
  
  <p>and my basic explanation was related that Aggregation indicates loose relationship while Composition indicates Strong relationship and clear explanation related to this.</p>
  
  <p>But the Interviewer Insulted me and said <strong>this is the theoretical concept about which you saying i want the perfect Java code in which how they differ and also told if i will give you one small Application then how would you identify that this is the Aggregation and this is the Composition?</strong> </p>
  
  <p>So now i want to understand pure Technical Concept and Java code in which how they differ and what it is?</p>