src/Debugger/Bar/TracePanel.php
public function enableStatistics($enable = true, $sortBy = 'averageTime')
    {
        if (!\in_array($sortBy, ['count', 'deltaTime', 'averageTime'], true)) {
            throw new \InvalidArgumentException("Cannot sort statistics by '$sortBy' column.");
        }

        $this->performStatistics = (bool) $enable;
        $this->sortBy = $sortBy;

        return $this;
    }
public function enableStatistics($enable = true, $sortBy = 'averageTime')
    {
        if (!\in_array($sortBy, ['count', 'deltaTime', 'averageTime'], true)) {
            throw new \InvalidArgumentException("Cannot sort statistics by '$sortBy' column.");
        }

        $this->performStatistics = (bool) $enable;
        $this->sortBy = $sortBy;

        return $this;
    }
public function enableStatistics ( $ enable = true , $ sortBy = 'averageTime' ) { if ( ! \ in_array ( $ sortBy , [ 'count' , 'deltaTime' , 'averageTime' ] , true ) ) { throw new \ InvalidArgumentException ( "Cannot sort statistics by '$sortBy' column." ) ; } $ this -> performStatistics = ( bool ) $ enable ; $ this -> sortBy = $ sortBy ; return $ this ; }
Enable or disable function time statistics.

@param  bool  enable statistics
@param  string  sort by column 'count', 'deltaTime' or 'averageTime'

@return TracePanel
@throws \InvalidArgumentException
Enable or disable function time statistics .