joeGrammar
Programmer
A question for all you pure virtual function experts out there
Say I have created a dll and I wanted to define functions within a class in a console application accessing this dll... then I would have to make the functions pure virtual and in turn make the class abstract.
When defining these functions in the console application I would just write:
classname::function(param)
{
body
}
and this should work. What if there are functions within the class that aren't pure virtual and need to be fed private member variables fed to the constructor(ie accessor function)
How can we pass values to the constructor when we can't instantiate the darn class? (THIS IS NOT MY CODE )
Any help would be appreciated
Say I have created a dll and I wanted to define functions within a class in a console application accessing this dll... then I would have to make the functions pure virtual and in turn make the class abstract.
When defining these functions in the console application I would just write:
classname::function(param)
{
body
}
and this should work. What if there are functions within the class that aren't pure virtual and need to be fed private member variables fed to the constructor(ie accessor function)
How can we pass values to the constructor when we can't instantiate the darn class? (THIS IS NOT MY CODE )
Any help would be appreciated