Simulated multiple inheritance pattern for C#
David Esparza-Guerrero has a trick to simulate multiple inheritance in C#
. This is not a perfect solution, but it's interesting to look at.
Too bad we can't use the same approach (using the implicit operator
) to have classes implement interfaces by delegation just like Delphi does with the implements keyword
. Compiler error CS0552 states that "You cannot create a user-defined conversion to or from an interface" :-(