Creates a new date. If no parameters are given, the current time is used.
public __construct ( integer $sec, integer $usec ) | ||
$sec | integer | Number of seconds since January 1st, 1970 |
$usec | integer | Microseconds |
public function __construct($date = null) { if ($date instanceof \DateTime) { $date = $date->getTimestamp(); } parent::__construct($date); }