Answer Posted / balbir
Aggregation differs from ordinary composition in that it
does not imply ownership. In composition, when the owning
object is destroyed, so are the contained objects. In
aggregation, this is not necessarily true. For example, a
university owns various departments (e.g., chemistry), and
each department has a number of professors. If the
university closes, the departments will no longer exist,
but the professors in those departments will continue to
exist. Therefore, a University can be seen as a composition
of departments, whereas departments have an aggregation of
professors. In addition, a Professor could work in more
than one department, but a department could not be part of
more than one university
Is This Answer Correct ? | 6 Yes | 1 No |
Post New Answer View All Answers
What is variable explain?
What is a byte string?
How to instantiate member inner class?
why we use merge option in hybernate pls give a ex snippet
Why do we need array in java?
What are controls and their different types in awt?
What are the five major types of reference sources?
How to make a class or a bean serializable?
What is a native method in java programming?
how many types of Inheritance?
What is the requirement of thread in java?
What does the ‘static’ keyword mean? Is it possible to override private or static method in java?
Variable of the boolean type is automatically initialized as?
Explain the features of interfaces in java?
How an object is serialized in java?