Returns date

@return \DateTime|null
421796
public function getValue()
	{
		if (strlen($this->value) > 0) {
			return \DateTime::createFromFormat($this->format, $this->value);
		}
		return null;
	}
386822
public function getFeedExportStartDate()
    {
        $file = new SplFileInfo($this->config->getFeedTmpFile());
        if (!$file->isFile()) {
            return null;
        }

        return new DateTime('@' . $file->getMTime());
    }
390100
def getTime(self):
    """"""
    command = '$GT'
    time = self.sendCommand(command)
    if time == ['OK','165', '165', '165', '165', '165', '85']:
      return NULL
    else:
      return datetime.datetime(year = int(time[1])+2000,
                               month = int(time[2]),
                               day = int(time[3]),
                               hour = int(time[4]),
                               minute = int(time[5]),
                               second = int(time[6]))
939118
public function getValue()
    {
        if ($this->value instanceof \DateTime) {
            $this->value->setTimezone(new \DateTimeZone('UTC'));

            return $this->value->format('Y-m-d\TH:i:s\Z');
        }

        return $this->value;
    }
1169297
public function date($date=null)
    {
        if(is_null($date)) {
            $date = $this->created_at;
        }
        return String::date($date);
    }
856077
public function getDateInterval()
    {
        if ( !$this->from && !$this->to ) {
            return null;
        }
        return $this->from->diff($this->to);
    }
254832
public function getTimezone()
    {
        $dateTime = new Date();
        $dateTime->setTimeZone(new DateTimeZone($this->cachetTimezone));

        return $dateTime->format('T');
    }
298682
public function dateTime()
	{
		return $this->registry()->isRegistered(self::REGISTRY_DATETIME)
			? $this->lookup(self::REGISTRY_DATETIME)
			: new \DateTime('now')
			;
	}
1298748
public function getTimezone()
    {
        if (null === $this->timezone) {
            $this->timezone = new DateTimeZone(date_default_timezone_get());
        }

        return $this->timezone;
    }
1183500
public function getLogDate() : DateTime
     {
        $rtn = $this->data['log_date'];

        if (!empty($rtn)) {
            $rtn = new DateTime($rtn);
        }

        return $rtn;
     }
535740
public function getTargetExpirationDate(): \Lullabot\Mpx\DataService\DateTime\DateTimeFormatInterface
    {
        if (!$this->targetExpirationDate) {
            return new NullDateTime();
        }

        return $this->targetExpirationDate;
    }
1098673
public function getDates()
    {
        $defaults = [static::CREATED_AT, static::UPDATED_AT];

        return $this->usesTimestamps() ? array_merge($this->dates, $defaults) : $this->dates;
    }
675511
public function getDateOfBirth() : ?DateTime
     {
        $rtn = $this->data['date_of_birth'];

        if (!empty($rtn)) {
            $rtn = new DateTime($rtn);
        }

        return $rtn;
     }
640298
public function getDeathDate(): Date
    {
        foreach ($this->getAllDeathDates() as $date) {
            if ($date->isOK()) {
                return $date;
            }
        }

        return new Date('');
    }
30515
public function currentDatetime()
    {
        if ($this->timeFormat === static::$timeFormatDatetime) {
            return date('Y-m-d H:i:s');
        }
        if ($this->timeFormat === static::$timeFormatTimestamp) {
            return time();
        }
        return null;
    }
449343
public function currentUtcDatetime()
    {
        if ($this->timeFormat === static::$timeFormatDatetime) {
            return gmdate('Y-m-d H:i:s');
        }
        if ($this->timeFormat === static::$timeFormatTimestamp) {
            return time();
        }
        return null;
    }
1075641
public function getTime($format = null)
    {
        //argument 1 must be a string or null
        Argument::i()->test(1, 'string', 'null');

        $time = $this->time + $this->offset;

        if (!is_null($format)) {
            return date($format, $time);
        }

        return $time;
    }