Using PInvoke vs .NET Functions

From version to version of .NET, more features equal to P / Invoke are added to .NET

Now I have 2 questions.

1) Which one is preferable to the other in speed, I usually use the .Net function, but in a narrow loop I really do not know which one will be faster.

2) Is there any website containing a list of counter parts?

+3
source share
1 answer

1) If you have a .NET function, you should, of course, use it - unless you have a really good reason not to.

2) , , API Win32 .NET, - ​​ .NET 1.1. . http://msdn.microsoft.com/en-us/library/aa302340.aspx

: , , , , - .NET framework (, mscorlib, System ..) Reflector search Win32. , , , , , , . , , P/Invoke, .

+4

Source: https://habr.com/ru/post/1741712/


All Articles