DateTimeOperations extension

on

Methods

endOfDay() DateTime
Create a new date setting hour to 23, minute to 59, and second to 59.
firstDayOfMonth() DateTime
Create a new first date of this month.
lastDayOfMonth() DateTime
Create a new last date of this month.
nextMonth() DateTime
Create a new date with next month values.
nextWeek() DateTime
Create a new date with next week values.
nextYear() DateTime
Create a new date with next year values.
onlyDate() DateTime
Create a new date with only date value (0 for hour, minute and second).
onlyTime() DateTime
Create a new date with only time value (0 for year, month and day).
previousMonth() DateTime
Create a new date with previous month values.
previousWeek() DateTime
Create a new date with previous week values.
previousYear() DateTime
Create a new date with previous year values.
startOfDay() DateTime
Create a new date setting hour, minute and second to 0.
tomorrow() DateTime
Create a new date with tomorrow values.
yesterday() DateTime
Create a new date with yesterday values.