/** * Initialize class if it was not previously initialized * * @return void */ protected static function initialize() { // Generally we want to base our intervals on a single time stamp // per execution. If you have a script that requires a new time stamp // for intervals simply remove if wrapper around this code if (!self::$date) { self::$date = new DateTime(); } if (!self::$format) { self::$format = 'Y-m-d H:i:s'; } }