mirror of https://github.com/dahall/Vanara.git
Added static Instance properties to IMemoryMethods implementations
parent
180dc255d8
commit
51edbded7c
|
@ -29,6 +29,10 @@ namespace Vanara.InteropServices
|
|||
public Action<IntPtr> FreeSecureStringUni => Marshal.ZeroFreeCoTaskMemUnicode;
|
||||
/// <summary>Gets the Ansi <see cref="SecureString"/> free method.</summary>
|
||||
public Action<IntPtr> FreeSecureStringAnsi => Marshal.ZeroFreeCoTaskMemAnsi;
|
||||
|
||||
|
||||
/// <summary>Static instance to methods.</summary>
|
||||
public static IMemoryMethods Instance { get; } = new CoTaskMemoryMethods();
|
||||
}
|
||||
|
||||
/// <summary>A <see cref="SafeHandle"/> for memory allocated via COM.</summary>
|
||||
|
|
|
@ -29,6 +29,9 @@ namespace Vanara.InteropServices
|
|||
public Action<IntPtr> FreeSecureStringUni => Marshal.ZeroFreeGlobalAllocUnicode;
|
||||
/// <summary>Gets the Ansi <see cref="SecureString"/> free method.</summary>
|
||||
public Action<IntPtr> FreeSecureStringAnsi => Marshal.ZeroFreeGlobalAllocAnsi;
|
||||
|
||||
/// <summary>Static instance to methods.</summary>
|
||||
public static IMemoryMethods Instance { get; } = new HGlobalMemoryMethods();
|
||||
}
|
||||
|
||||
/// <summary>A <see cref="SafeHandle"/> for memory allocated via LocalAlloc.</summary>
|
||||
|
|
Loading…
Reference in New Issue