Neos\Flow\Persistence\Generic\DataMapper::mapDateTime PHP Method

mapDateTime() protected method

Creates a \DateTime from an unix timestamp. If the input is not an integer NULL is returned.
protected mapDateTime ( integer $timestamp ) : DateTime
$timestamp integer
return DateTime
    protected function mapDateTime($timestamp)
    {
        $datetime = new \DateTime();
        $datetime->setTimestamp((int) $timestamp);
        return $datetime;
    }