Class NativeLibraries¶
Namespace: Apogee.Interop
Assembly: Apogee.Interop.dll
Resolves the native libraries behind generated DllImports. A binding assembly registers each logical library
name once, with the file names to try per operating system.
public static class NativeLibraries
Inheritance¶
Inherited Members¶
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Methods¶
Register(Assembly, string, string[], string[], string[])¶
Registers the candidate file names for logicalName, the name used in the DllImports of assembly.
public static void Register(Assembly assembly, string logicalName, string[] linux, string[] windows, string[] macos)
Parameters¶
assembly Assembly
logicalName string
linux string[]
windows string[]
macos string[]
TryLoad(Assembly, string, out nint)¶
Loads the library registered as logicalName for assembly, or returns false when none of its candidates loads.
public static bool TryLoad(Assembly assembly, string logicalName, out nint handle)
Parameters¶
assembly Assembly
logicalName string
handle nint