Thursday, February 3, 2011
Interface
An Interface is not a class. It is an entity that is defined by the word Interface . An Interface has no implementation; it only has the signature or in other words, just the definition of the methods without the body. As one of the similarities to abstract class it is a contract that is used to define hierarchies for all subclasses or it defines specific set of methods and their arguments. The main difference between them is that a class can implement more than one Interface but can only inherit from oneabstract class. Since C# doesn't support multiple inheritance, Interface are used to implement multiple inheritance.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment