|
-
May 31st, 2004, 01:24 PM
#1
Thread Starter
Hyperactive Member
abstract classes vs interfaces
Big problem ... I have a test tomorrow about Polymorphism, inheritance, interfaces and abstract classes in C#.
My main question is... abstract classes and interfaces seem to do the same thing ? (Or am i missing something ?)
Then when do you use a abstract class and when do you prefer an interface instead ?
Thanks in advance
____________________________________________
Please rate my messages. Thank you!
____________________________________________
Bram Vandenbon
http://www.bramvandenbon.com
-
May 31st, 2004, 03:48 PM
#2
Sleep mode
Off the top of my head ,
classes can inherit one class but many interfaces .So, using interfaces would give you multiple inheritance .
abstract classes :
1- usually used as base classes
2-can't be instantiated.
-
May 31st, 2004, 04:57 PM
#3
Thread Starter
Hyperactive Member
thank you very much ! that's a great answer, my compliments
____________________________________________
Please rate my messages. Thank you!
____________________________________________
Bram Vandenbon
http://www.bramvandenbon.com
-
May 31st, 2004, 05:08 PM
#4
Sleep mode
You should check MSDN for more info .It's helpful with examples.
good luck in your test.
-
May 31st, 2004, 05:18 PM
#5
Thread Starter
Hyperactive Member
thanks 
I've put up another post about another question. Who knows , you might be able to help there too ? would be great
____________________________________________
Please rate my messages. Thank you!
____________________________________________
Bram Vandenbon
http://www.bramvandenbon.com
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|