Say I have 4 classes A, B, C, and D, and I want to use all 4 within a class that is implementing pure virtual functions from another .h file User. My question is how can I include those 4 classes into one .h so the .cpp of that .h will allow me to call those functions within the classes.
This is what I have tried so far:
#include "User.h"
#include "A.h"
#include "B.h"
#include "C.h"
#include "D.h"
Class create : public User, public A, public B, public C, public D
{
public:
create();
virtual ~create();
bool a1();
bool b1();
bool c1();
bool d1();
int a2();
int b2();
int c2();
int d2();
};
Then when I try to call those functions (declared in A.cpp, B.ccp, C.cpp, D.cpp) in the create.cpp I am being told "undefined reference to A::a1( )... and so on.
Does this make sense?