开发者

COM vs tightly wrapped managed c++ objects

开发者 https://www.devze.com 2023-01-16 03:20 出处:网络
So, there is a legacy code that has to be imported into .NET projects. Which one do you preffer, and why:

So, there is a legacy code that has to be imported into .NET projects.

Which one do you preffer, and why:

  • packing it into COM module

开发者_Python百科or

  • making small and tight c++ managed wrapper around it

There is third option of exporting the functions in the DLL, but let's say that we want classes here.


Myself, I would rather chew my leg of then go with COM. There are numerous times when my setup & deployment project collects wrong version of COM .dll (debug instead of release) and smoke-testing EACH build is just bit of an overkill for me.

Once written and tested, managed c++ wrapper never broke. At least for me.

0

精彩评论

暂无评论...
验证码 换一张
取 消