Joomla CMS  4.2.2
Documentation des API du CMS Joomla en version 4.2.2
Référence de la classe DayOfMonthField
+ Graphe d'héritage de DayOfMonthField:

Fonctions membres publiques

 isSatisfiedBy (DateTimeInterface $date, $value, bool $invert)
 
 increment (DateTimeInterface &$date, $invert=false, $parts=null)
 
 validate (string $value)
 
- Fonctions membres publiques hérités de AbstractField
 __construct ()
 
 isSatisfied (int $dateValue, string $value)
 
 isRange (string $value)
 
 isIncrementsOfRanges (string $value)
 
 isInRange (int $dateValue, $value)
 
 isInIncrementsOfRanges (int $dateValue, string $value)
 
 getRangeForExpression (string $expression, int $max)
 
 validate (string $value)
 

Attributs protégés

 $rangeStart = 1
 
 $rangeEnd = 31
 
- Attributs protégés hérités de AbstractField
 $fullRange = []
 
 $literals = []
 
 $rangeStart
 
 $rangeEnd
 

Fonctions membres privées statiques

static getNearestWeekday (int $currentYear, int $currentMonth, int $targetDay)
 

Membres hérités additionnels

- Fonctions membres protégées hérités de AbstractField
 convertLiterals (string $value)
 
 timezoneSafeModify (DateTimeInterface $dt, string $modification)
 
 setTimeHour (DateTimeInterface $date, bool $invert, int $originalTimestamp)
 

Description détaillée

Day of month field. Allows: * , / - ? L W.

'L' stands for "last" and specifies the last day of the month.

The 'W' character is used to specify the weekday (Monday-Friday) nearest the given day. As an example, if you were to specify "15W" as the value for the day-of-month field, the meaning is: "the nearest weekday to the 15th of the month". So if the 15th is a Saturday, the trigger will fire on Friday the 14th. If the 15th is a Sunday, the trigger will fire on Monday the 16th. If the 15th is a Tuesday, then it will fire on Tuesday the 15th. However if you specify "1W" as the value for day-of-month, and the 1st is a Saturday, the trigger will fire on Monday the 3rd, as it will not 'jump' over the boundary of a month's days. The 'W' character can only be specified when the day-of-month is a single day, not a range or list of days.

Auteur
Michael Dowling mtdow.nosp@m.ling.nosp@m.@gmai.nosp@m.l.co.nosp@m.m

Documentation des fonctions membres

◆ getNearestWeekday()

static getNearestWeekday ( int  $currentYear,
int  $currentMonth,
int  $targetDay 
)
staticprivate

Get the nearest day of the week for a given day in a month.

Paramètres
int$currentYearCurrent year
int$currentMonthCurrent month
int$targetDayTarget day of the month
Renvoie
|null Returns the nearest date

Références $i, $target, et null.

◆ increment()

increment ( DateTimeInterface &  $date,
  $invert = false,
  $parts = null 
)
Paramètres
\DateTime | \DateTimeImmutable$date

Implémente FieldInterface.

Références $date, et $this.

◆ isSatisfiedBy()

isSatisfiedBy ( DateTimeInterface  $date,
  $value,
bool  $invert 
)

{Check if the respective value of a DateTime field satisfies a CRON exp.}

Implémente FieldInterface.

Références $date, $fieldValue, et $value.

◆ validate()

validate ( string  $value)

{Validates a CRON expression for a given field.

Paramètres
string$valueCRON expression value to validate
Renvoie
bool Returns TRUE if valid, FALSE otherwise
}

Implémente FieldInterface.

Références $value.

Documentation des champs

◆ $rangeEnd

$rangeEnd = 31
protected

{}

◆ $rangeStart

$rangeStart = 1
protected

{}


La documentation de cette classe a été générée à partir du fichier suivant :