C H A P T E R 15
- What Is an Interface?
- Declaring an Interface
- Implementing an Interface
- An Interface Is a Reference Type
- Using the as Operator with Interfaces
- Implementing Multiple Interfaces
- Implementing Interfaces with Duplicate Members
- References to Multiple Interfaces
- An Inherited Member As an Implementation
- Explicit Interface Member Implementations
- Interfaces Can Inherit Interfaces
- Example of Different Classes Implementing an Interface
What Is an Interface?
An interface is a reference type that specifies a set of function members but does not implement them. That's left to classes and structs that implement the interface. This description sounds pretty abstract, so let me first show you the problem that an interface helps ...