public static int CompareRounded(this DateTime?x, DateTime?y, TimeSpan interval) { var comparer = new RoundedDateTimeComparer(interval); return(comparer.Compare(x, y)); }
public static bool EqualsRounded(this DateTime?x, DateTime?y, TimeSpan interval) { var comparer = new RoundedDateTimeComparer(interval); return(comparer.Equals(x, y)); }