Method Load
- Namespace
- Ubiquity.NET.InteropHelpers
- Assembly
- Ubiquity.NET.InteropHelpers.dll
Load(string, Assembly, DllImportSearchPath?)
Provides a high-level API for loading a native library.
public static NativeLibraryHandle Load(string libraryName, Assembly assembly, DllImportSearchPath? searchPath)
Parameters
libraryNamestringThe name of the native library to be loaded.
assemblyAssemblyThe assembly loading the native library.
searchPathDllImportSearchPath?The search path.
Returns
- NativeLibraryHandle
The OS handle for the loaded library.
Exceptions
- ArgumentNullException
libraryNameorassemblyis null.- ArgumentException
assemblyis not aRuntimeAssembly.- DllNotFoundException
The library can't be found.
- BadImageFormatException
The library is not valid.