T
The Cool Giraffe
I'm designing an ABC and in connection to that i have run
into some "huh!" and "oh...". Let me put it as a list.
1. Since the class will only contain bodies of the methods,
only the header file is needed. There will be no definitions
provided until i derive the ABC. True or false?
2. Since i'll have two different classes (both derived from
the original ABC) i'll use the following syntax in my main
class using the derivation.
AbstractClass* obj;
obj = DerivedClassA ();
Is that correct? Do i need "new" somewhere? I'm a Java
boy really so i like using "new" every now and then...
3. I have looked through the whole of the internet (almost*)
for a simple syntax example that will show how to set up
such a derivation scheme but to no avail. Any pointers?
*almost = until i got tired after about 2 hours
into some "huh!" and "oh...". Let me put it as a list.
1. Since the class will only contain bodies of the methods,
only the header file is needed. There will be no definitions
provided until i derive the ABC. True or false?
2. Since i'll have two different classes (both derived from
the original ABC) i'll use the following syntax in my main
class using the derivation.
AbstractClass* obj;
obj = DerivedClassA ();
Is that correct? Do i need "new" somewhere? I'm a Java
boy really so i like using "new" every now and then...
3. I have looked through the whole of the internet (almost*)
for a simple syntax example that will show how to set up
such a derivation scheme but to no avail. Any pointers?
*almost = until i got tired after about 2 hours