public function getDuration()
    {
        $ended = microtime(true);
        if ($this->ended) {
            $ended = strtotime($this->ended);
        }
        $started = strtotime($this->started);

        return Date::niceDuration($ended-$started);
    }
public function getDuration()
    {
        $ended = microtime(true);
        if ($this->ended) {
            $ended = strtotime($this->ended);
        }
        $started = strtotime($this->started);

        return Date::niceDuration($ended-$started);
    }
public function getDuration ( ) { $ ended = microtime ( true ) ; if ( $ this -> ended ) { $ ended = strtotime ( $ this -> ended ) ; } $ started = strtotime ( $ this -> started ) ; return Date :: niceDuration ( $ ended - $ started ) ; }
Get duration.

@return [[@doctodo return_type:getDuration]] [[@doctodo return_description:getDuration]]
Get duration .