library/Odesk/Phystrix/MetricsCounter.php
public function get($type)
    {
        $sum = 0;
        $now = $this->getTimeInMilliseconds();

        for ($i = 0; $i < $this->rollingStatisticalWindowBuckets; $i++) {
            $bucketIndex = $this->getBucketIndex($i, $now);
            $sum += $this->stateStorage->getBucket($this->commandKey, $type, $bucketIndex);
        }

        return $sum;
    }
public function get($type)
    {
        $sum = 0;
        $now = $this->getTimeInMilliseconds();

        for ($i = 0; $i < $this->rollingStatisticalWindowBuckets; $i++) {
            $bucketIndex = $this->getBucketIndex($i, $now);
            $sum += $this->stateStorage->getBucket($this->commandKey, $type, $bucketIndex);
        }

        return $sum;
    }
public function get ( $ type ) { $ sum = 0 ; $ now = $ this -> getTimeInMilliseconds ( ) ; for ( $ i = 0 ; $ i < $ this -> rollingStatisticalWindowBuckets ; $ i ++ ) { $ bucketIndex = $ this -> getBucketIndex ( $ i , $ now ) ; $ sum += $ this -> stateStorage -> getBucket ( $ this -> commandKey , $ type , $ bucketIndex ) ; } return $ sum ; }
Calculates sum for given metric type within the statistical window

@param integer $type
@return integer
Calculates sum for given metric type within the statistical window