Skip to content

Opening book details…

Can I read Aggregation vs. Inheritance in OOP on EtoBox?

Aggregation vs. Inheritance in OOP by Bugnaru Gelu is a document available to read on EtoBox.

What is Aggregation vs. Inheritance in OOP about?

This document compares aggregation and inheritance as techniques for code reuse. It provides examples of implementing a Stack class using both aggregation of a Vector class and inheritance from the Vector class. Aggregation involves creating a Stack object that contains a Vector object, allowing Stack methods to delegate work to Vector methods. Inheritance involves declaring Stack as a subclass of Vector so it inherits Vector

Author
Bugnaru Gelu
Language
EN

More by Bugnaru Gelu

Browse all works by Bugnaru Gelu