Why do we use aggregation in Java?

Aggregation helps in reusing the code . Object B can have utility methods and which can be utilized by multiple objects. Whichever class has object B then it can utilize its methods.

Sizin İçin Seçtik  What are the main parts of Java?

Leave a Reply

Your email address will not be published. Required fields are marked *

Why do we use aggregation in Java?

Aggregation helps in reusing the code . Object B can have utility methods and which can be utilized by multiple objects. Whichever class has object B then it can utilize its methods.

Sizin İçin Seçtik  What is composition in csharp?

Leave a Reply

Your email address will not be published. Required fields are marked *