DatePeriods
Class for getting various dates related to the formation of terms.
Table of Contents
Methods
- __construct() : mixed
- afterNextWeek() : Date
- calculateDateByStage() : Date|null
- currentWeekLastDay() : Date
- nextWeekFirstDay() : Date
- nextWeekLastDay() : Date
- stageByDate() : string
- today() : Date
- tomorrow() : Date
Methods
__construct()
public
__construct([Datetime|null $now = null ]) : mixed
Parameters
- $now : Datetime|null = null
afterNextWeek()
public
afterNextWeek() : Date
Return values
DatecalculateDateByStage()
public
calculateDateByStage(string $stage) : Date|null
Parameters
- $stage : string
Return values
Date|nullcurrentWeekLastDay()
public
currentWeekLastDay() : Date
Return values
DatenextWeekFirstDay()
public
nextWeekFirstDay() : Date
Return values
DatenextWeekLastDay()
public
nextWeekLastDay() : Date
Return values
DatestageByDate()
public
stageByDate(Date|null $checkDate) : string
Parameters
- $checkDate : Date|null
Return values
stringtoday()
public
today() : Date
Return values
Datetomorrow()
public
tomorrow() : Date