This is a discussion on List out all the similarities/difference between an Abstract class and Interface? within the ASP and ASP.NET Programming forums, part of the Web Development category; list out all the similarities/difference between an Abstract class and Interface?...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Differences are as follows: Interfaces provide a form of multiple inheritance. A class can extend only one other class. Interfaces are limited to public methods and constants with no implementation. Abstract classes can have a partial implementation, protected parts, static methods, etc. A Class may implement several interfaces. But in case of abstract class, a class may extend only one abstract class. Interfaces are slow as it requires extra indirection to to find corresponding method in in the actual class. Abstract classes are fast. |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Difference between abstract class and interface | srikumar_l | C# Programming | 0 | 12-17-2007 03:18 AM |
| difference between abstract class and interface | vijayanand | Java Programming | 2 | 11-27-2007 09:19 PM |
| Similarities and Difference between C# and Other Languages | Sundaram | C# Programming | 3 | 09-01-2007 12:14 AM |
| What’s the difference between an interface and an abstract class? | Sabari | Java Programming | 1 | 07-17-2007 05:00 AM |
| Abstract Class | nhoj | Java Programming | 1 | 05-08-2007 05:35 AM |