public static function fromTimeOfDay(array $tod)
    {
        $str = $tod['sec'] . str_pad($tod['usec'], 6, '0', STR_PAD_LEFT);
        $m = new self();
        $m->int = (int)$str;
        $m->sec = (int)substr($str, 0, 10);
        $m->usec = (int)substr($str, -6);
        return $m;
    }
public static function fromTimeOfDay(array $tod)
    {
        $str = $tod['sec'] . str_pad($tod['usec'], 6, '0', STR_PAD_LEFT);
        $m = new self();
        $m->int = (int)$str;
        $m->sec = (int)substr($str, 0, 10);
        $m->usec = (int)substr($str, -6);
        return $m;
    }
public static function fromTimeOfDay ( array $ tod ) { $ str = $ tod [ 'sec' ] . str_pad ( $ tod [ 'usec' ] , 6 , '0' , STR_PAD_LEFT ) ; $ m = new self ( ) ; $ m -> int = ( int ) $ str ; $ m -> sec = ( int ) substr ( $ str , 0 , 10 ) ; $ m -> usec = ( int ) substr ( $ str , - 6 ) ; return $ m ; }
Create a new object from the result of a gettimeofday call that
is NOT returned as a float.

@link http://php.net/manual/en/function.gettimeofday.php

@param array $tod

@return self
Create a new object from the result of a gettimeofday call that is NOT returned as a float .