[LC++]virtual protected?

Roberto Diaz roberto at vivaldi.dhis.org
Fri Dec 21 14:46:12 UTC 2001


Hi!

I want to make something like this: (this pseudocode doesnt work.. of course)

class base 
{
	private:
	virtual void doSomething();
};

I mean I woul like to have a method which could be overided in the derived
classes but not exposed in the objects..

if i do:

class base
{
	public:
	virtual void doSomething();
};

I can overide.. but the method is exposed..

If I do:

class base
{
	protected:
	virtual void doSomething ();
};

The compiler complains.. 

Some ideas please? 


Saludos

Roberto Díaz <roberto at vivaldi.dhis.org>

PLEASE HELP SAVE faqs.org!
http://www.faqs.org/save_faqs-org.html



More information about the tuxCPProgramming mailing list