.Net Interface / Abstract Class 分別

 
.Net Interface / Abstract Class 分別
 
An Interface cannot implement methods.
An abstract class can implement methods.
 
An Interface can only inherit from another Interface.
An abstract class can inherit from a class and one or more interfaces.
 
An Interface cannot contain fields.
An abstract class can contain fields.
 
An Interface can contain property definitions.
An abstract class can implement a property.
 
An Interface cannot contain constructors or destructors.
An abstract class can contain constructors or destructors.
 
An Interface can be inherited from by structures.
An abstract class cannot be inherited from by structures.
 
An Interface can support multiple inheritance.
An abstract class cannot support multiple inheritance.
 
Reference From : http://en.csharp-online.net/Interfaces_and_Abstract_Classes