/// <summary> /// Throws an <see cref="System.ArgumentException"/> if the argument value /// does not match the expected value as defined by the given function. /// </summary> /// <typeparam name="T">The type of the argument.</typeparam> /// <param name="argValue">The argument value.</param> /// <param name="expectedValue">The expected value.</param> /// <param name="function">The comparison function to be used.</param> /// <param name="argName">The argument name.</param> public static void Is <T>(T argValue, T expectedValue, Func <T, T, bool> function, string argName) { Insist.Is <T>(argValue, expectedValue, function, argName, null); }