0
How to create interfaces in C++?
If anyone could give me an example of creating interfaces in C++, something similar to C# or Java. I could google it, but prefer something from this platform. Thanks
1 Réponse
0
C++ has no built-in concepts of interfaces. You could implement it with abstract classes which contain only pure virtual functions. Due to it allowing multiple inheritance, you can inherit this class so that you can create another class which will contain this interface(I mean object interface) in it.
Here is an example:-
https://hastebin.com/evelofoqub.cpp