public WindowsProtectedMemoryAllocatorTest() { if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { windowsProtectedMemoryAllocator = new WindowsProtectedMemoryAllocatorVirtualAlloc(); } }
public WindowsProtectedMemoryAllocatorTest() { Trace.Listeners.Clear(); var consoleListener = new ConsoleTraceListener(); Trace.Listeners.Add(consoleListener); var configuration = new ConfigurationBuilder().AddInMemoryCollection(new Dictionary <string, string> { { "minimumWorkingSetSize", "33554430" }, { "maximumWorkingSetSize", "67108860" }, }).Build(); if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { windowsProtectedMemoryAllocator = new WindowsProtectedMemoryAllocatorVirtualAlloc(configuration); } }