How to implement a private virtual function within derived classes?
- by Dane
Hi,
I know why I want to use private virtual functions, but how exactly can I implement them?
For example:
class Base{
[...]
private:
virtual void func() = 0;
[...]
}
class Derived1: puplic Base{
void func()
{ //short implementation is ok here
}
}
class Derived2: puplic Base{
void func(); //long implementation elsewhere (in cpp…