public function average(callable $callback = null)
    {

        if ($callback ===  null) {

            $average = parent::average(function ($time)
            {
                return $time->getSeconds();
            });

            return $this->createTime(0, 0, $average);
        }

        return parent::average($callback);
    }
public function average(callable $callback = null)
    {

        if ($callback ===  null) {

            $average = parent::average(function ($time)
            {
                return $time->getSeconds();
            });

            return $this->createTime(0, 0, $average);
        }

        return parent::average($callback);
    }
public function average ( callable $ callback = null ) { if ( $ callback === null ) { $ average = parent :: average ( function ( $ time ) { return $ time -> getSeconds ( ) ; } ) ; return $ this -> createTime ( 0 , 0 , $ average ) ; } return parent :: average ( $ callback ) ; }
Returns the averaged time of the collection
@return Time
Returns the averaged time of the collection