Can .NET PInvoke Interop SDK wrap native C++ class?

Yes. It supports P/Invoke native C++ class. For every exported class in the C++ DLL, the C# Wrapper Generator for C++ DLL will generate a corresponding .NET C# wrapper class in the C# wrapper library. The C# wrapper class implements exactly the same interface of the original C++ class, which makes developers feel like calling (P/Invoke) C++ class method with the convenience of using it from C# language. The C# wrapper class can be created in C# hence the C++ class can be instantiated from C#, the C++ DLL will see no difference between the object of C++ class created from C# and the object created from C++ DLL.


← Faqs
Translate »