Created
June 26, 2011 06:36
-
-
Save jittuu/1047322 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class DateTimeExtensions | |
{ | |
public static bool IsAfter(this DateTime current, DateTime value) | |
{ | |
return current > value; | |
} | |
public static bool IsBefore(this DateTime current, DateTime value) | |
{ | |
return current < value; | |
} | |
public static bool IsAfterDate(this DateTime current, DateTime value) | |
{ | |
return current.Date > value.Date; | |
} | |
public static bool IsBeforeDate(this DateTime current, DateTime value) | |
{ | |
return current.Date < value.Date; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment