Avatar of jxbma
jxbma
Flag for United States of America asked on

Are Interfaces supported in (Microsoft) unmanaged C++?

Hi:

In the C#/.Net Managed Interfaces are supported.

Are interfaces supported in unmanaged C++?
I know I can create an abstract class with virtual function pointers which simulate an interface definition.
But, does the concept of a C# style interface exist?


Thanks,
JohnB
C++C#

Avatar of undefined
Last Comment
phoffric

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Carl Tawn

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
jxbma

ASKER
Cool beans.
That's what I thought.
phoffric

One of my C++ projects required interfaces. This was implemented using abstract classes with only pure virtual functions and no implementations and no data members; and also used virtual destructors.
jxbma

ASKER
phoffric::>> How did you wrap/expose the classes in that project to be consumed by a C# (managed) client?

Thanks,
JB
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
phoffric

>> How did you wrap/expose the classes in that project to be consumed by a C#
This question was not in the OP. My project didn't use C# so this was a non-issue.