You are here

public function DateArgumentWrapper::createDateTime in Calendar 8

3 calls to DateArgumentWrapper::createDateTime()
DateArgumentWrapper::format in src/DateArgumentWrapper.php
DateArgumentWrapper::getMaxDate in src/DateArgumentWrapper.php
Function to get max date.
DateArgumentWrapper::getMinDate in src/DateArgumentWrapper.php
Function to get min date.

File

src/DateArgumentWrapper.php, line 104

Class

DateArgumentWrapper
The DateArgumentWrapper class.

Namespace

Drupal\calendar

Code

public function createDateTime() {
  if ($value = $this->dateArg
    ->getValue()) {
    if (!$this
      ->validateValue()) {
      return FALSE;
    }
    return $this
      ->createFromFormat($value);
  }
  return NULL;
}