OOPS
August 29, 2024OOPS
August 29, 2024OOPS
Question 167 |
Which of the following statements is correct?
Aggregation is a strong type of association between two classes with full ownership | |
Aggregation is a strong type of association between two classes with partial ownership. | |
Aggregation is a weak type of association between two classes with partial ownership. | |
Aggregation is a weak type of association between two classes with full ownership. |
Question 167 Explanation:
Aggregation is a special form of association. It is a relationship between two classes like association, however its a directional association, which means it is strictly a one way association. It represents a HAS-A relationship.
For example consider two classes Student class and Address class. Every student has an address so the relationship between student and address is a Has-A relationship. But if you consider its vice versa then it would not make any sense as an Address doesn’t need to have a Student necessarily.
Correct Answer: C
Question 167 Explanation:
Aggregation is a special form of association. It is a relationship between two classes like association, however its a directional association, which means it is strictly a one way association. It represents a HAS-A relationship.
For example consider two classes Student class and Address class. Every student has an address so the relationship between student and address is a Has-A relationship. But if you consider its vice versa then it would not make any sense as an Address doesn’t need to have a Student necessarily.