<PackageReference Include="Microsoft.Win32.SystemEvents" Version="11.0.0-preview.7.26381.103" />

System.ExceptionPolyfills

static class ExceptionPolyfills

public static void ThrowIf(bool condition, object instance)

public static void ThrowIf(bool condition, Type type)

public static void ThrowIfGreaterThan<T>(T value, T other, string paramName = null) where T : IComparable<T>

public static void ThrowIfGreaterThanOrEqual<T>(T value, T other, string paramName = null) where T : IComparable<T>

public static void ThrowIfLessThan<T>(T value, T other, string paramName = null) where T : IComparable<T>

public static void ThrowIfLessThanOrEqual<T>(T value, T other, string paramName = null) where T : IComparable<T>

public static void ThrowIfNegative(int value, string paramName = null)

public static void ThrowIfNegative(long value, string paramName = null)

public static void ThrowIfNull(object argument, string paramName = null)

public static void ThrowIfNullOrEmpty(string argument, string paramName = null)