+ 1

Need help with aggregation ,how to wright?

I need to create 2 classes : shop and products wich in relation with aggregation . There i need a default constructor and a constructor with parameter . And functions: foo_past(past an element in a place we need ). Foo_show(shows a product list ) Foo_search(searching the product in a list) Foo_delete(deleting the list) And a destructor. Если что я русскоязычный,ребят,помогите,не шарю )

2nd Nov 2017, 10:51 PM
Jimmy Pub
Jimmy Pub - avatar
3 Réponses
+ 8
I would start by aggregating the products class in the shop class, since a shop uses-a products. So, you would declare a pointer to the products class inside the shop class. The rest should be easy.
2nd Nov 2017, 11:06 PM
Karl T.
Karl T. - avatar
0
Oh...pointers ,i have trouble in understanding their using. Know what are they doing but couldn't use them in a right way
2nd Nov 2017, 11:17 PM
Jimmy Pub
Jimmy Pub - avatar
0
Hey,do u still here? I really need your help)
2nd Nov 2017, 11:40 PM
Jimmy Pub
Jimmy Pub - avatar