Object intercommunication is at the heart of object-oriented systems. The relationship is the logical link between objects. The way we can distinguish or set up a proper relationship between classes of objects defines both the performance and quality of the system design overall. Consider the Product and Warehouse classes; they are in a relationship called aggregation because the Warehouse contains Products, that is, the Warehouse aggregates Products:
![](https://static.packt-cdn.com/products/9781838552657/graphics/assets/76b956c9-22ba-4ee7-af40-f4edc84ae8ca.png)
There are several kinds of relationships in terms of pure OOP, such as association, aggregation, composition, instantiation, generalization, and others.