Social Sciences, asked by LsEmpire5734, 1 year ago

Which concept depicts the use of object of one class as a data member of another class c)compasition?

Answers

Answered by writersparadise
0
The properties of one class can be used by declaring the object as class data member in another class. This is called as Delegation.

The class which has an object as a member of another class, it is called as a container class.

In Delegation, the composed class consists of objects from other classes and uses their properties through their objects. This kind of relation is usually termed as “has-a-relationship” or “has-a-containership”.
Similar questions