I have a Class A that is part of a library that I want to use in Class B. How do I put Class A as a private member in Class B if Class A doesn't have a default constructor? B needs to be inited with several variables and I would like to init it elsewhere if possible.
class A { public: A(); ~A();
private: B b; };
Aucun commentaire:
Enregistrer un commentaire