R
Raf256
Hi,
I would extend class only a bit. In example: I want to write my own class,
that works all like std::string, only it also have member int mDatabase;
and it have method SaveToDatabase();
I could do like:
class cStorableStr : std::string {
private:
int mDatabase;
public:
std::string:perator=;
void SaveToDatabase();
};
that inherits all methods from std::string, and operator(s) =.
But what if I would like to just unherit ALL. ALL operators, or ALL
members+operators. Is there a syntax allowing that?
Like:
public: std::string::*;
If not, perhaps it would be nice to have it?
I would extend class only a bit. In example: I want to write my own class,
that works all like std::string, only it also have member int mDatabase;
and it have method SaveToDatabase();
I could do like:
class cStorableStr : std::string {
private:
int mDatabase;
public:
std::string:perator=;
void SaveToDatabase();
};
that inherits all methods from std::string, and operator(s) =.
But what if I would like to just unherit ALL. ALL operators, or ALL
members+operators. Is there a syntax allowing that?
Like:
public: std::string::*;
If not, perhaps it would be nice to have it?