Interface Inheritance
Get familiar with the concepts of interfaces in general and the interface inheritance in detail.
Interfaces
The interface keyword is for defining interfaces in class hierarchies. interface is very similar to class with the following restrictions:
-
The member functions that it declares (but not implements) are abstract even without the
abstractkeyword. -
The member functions that it implements must be
staticorfinal. (staticandfinalmember functions are explained later in this chapter.) -
Its member variables must be
static. -
Interfaces can inherit only interfaces.
Despite these restrictions, there ...