-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathIntervalExtensions.cs
More file actions
19 lines (15 loc) · 1 KB
/
IntervalExtensions.cs
File metadata and controls
19 lines (15 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
using System;
namespace Ako.IntervalCore.Extensions
{
public static class IntervalExtensions
{
public static Interval<T> IntervalUntil<T>(this T start, T? end, bool excludeStart = false, bool excludeEnd = false)
where T : struct, IComparable, IConvertible => new(start, end, excludeStart, excludeEnd);
public static Interval<T> IntervalUntil<T>(this T? start, T? end, bool excludeStart = false, bool excludeEnd = false)
where T : struct, IComparable, IConvertible => new(start, end, excludeStart, excludeEnd);
public static Interval<T> IntervalFrom<T>(this T end, T? start, bool excludeStart = false, bool excludeEnd = false)
where T : struct, IComparable, IConvertible => new(start, end, excludeStart, excludeEnd);
public static Interval<T> IntervalFrom<T>(this T? end, T? start, bool excludeStart = false, bool excludeEnd = false)
where T : struct, IComparable, IConvertible => new(start, end, excludeStart, excludeEnd);
}
}