An interface can be based on one or many other interfaces. This way the interface inherits the methods defined in the parent interfaces. An implementation of such an interface can re-implement the methods of the parent interfaces. It is also possible to use existing implementations of the inherited interfaces when the component is registered.
Parent interfaces are defined with the MAXON_INTERFACE_BASES attribute. The default parent interface is maxon::ObjectInterface.
This example declares an interfaces that is directly based on maxon::ObjectInterface and an interface based on the previous interface:
Within the functions of an implementation it is possible to access the inherited functions using super:
The result class can be used like this:
Additional components are typically implementations of the inherited interfaces and define the specific behaviour of the registered component. They can be added using the MAXON_COMPONENT() attribute or by implementing maxon::ComponentRoot::ConfigureClass().