Xhgui_Profile::_maxValue PHP Method

_maxValue() protected method

Get the max value for any give metric.
protected _maxValue ( string $metric )
$metric string The metric to get a max value for.
    protected function _maxValue($metric)
    {
        return array_reduce($this->_collapsed, function ($result, $item) use($metric) {
            if ($item[$metric] > $result) {
                return $item[$metric];
            }
            return $result;
        }, 0);
    }