DateTimeExtensions extension
- on
Properties
- endOfDay → DateTime
-
Available on DateTime, provided by the DateTimeExtensions extension
Returns the end of the day for the DateTimeno setter - isEvenHour → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current hour is evenno setter - isEvenMinute → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current minute is evenno setter - isInFuture → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is in the futureno setter - isInPast → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is in the pastno setter - isOddHour → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current hour is oddno setter - isOddMinute → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current minute is oddno setter - isToday → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is todayno setter - isTomorrow → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is tomorrowno setter - isWeekend → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the date is a weekendno setter - isYesterday → bool
-
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is yesterdayno setter - startOfDay → DateTime
-
Available on DateTime, provided by the DateTimeExtensions extension
Returns the start of the day for the DateTimeno setter
Methods
-
addHours(
int hours) → DateTime -
Available on DateTime, provided by the DateTimeExtensions extension
Adds a specified number of hours to the current DateTime -
addMinutes(
int minutes) → DateTime -
Available on DateTime, provided by the DateTimeExtensions extension
Adds a specified number of minutes to the current DateTime -
isSameDate(
DateTime other) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is on the same day asother
-
isSameMonth(
DateTime other) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is in the same month asother
-
isSameWeek(
DateTime other) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is in the same week asother
-
isSameYear(
DateTime other) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date is in the same year asother
-
isTimeWithinRange(
TimeOfDay start, TimeOfDay end) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current time is within a time range (ignores date) -
isWithinNextHours(
int hours) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current time is within the next N hours -
isWithinNextMinutes(
int minutes) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current time is within the next N minutes -
isWithinPastHours(
int hours) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current time is within the past N hours -
isWithinPastMinutes(
int minutes) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current time is within the past N minutes -
isWithinRange(
DateTime start, DateTime end) → bool -
Available on DateTime, provided by the DateTimeExtensions extension
Checks if the current date falls within a range ofstart
andend
-
subtractHours(
int hours) → DateTime -
Available on DateTime, provided by the DateTimeExtensions extension
Subtracts a specified number of hours from the current DateTime -
subtractMinutes(
int minutes) → DateTime -
Available on DateTime, provided by the DateTimeExtensions extension
Subtracts a specified number of minutes from the current DateTime