public function doTic()
    {
        $aData = &$this->aData;
        $fNow = microtime(true);

        if ($fNow >= $aData['lap_end'] || $this->isTimeLimitExceeded()) {
            $iNbEventsPerSec = round($aData['lap_nb_events'] / ($fNow - $aData['lap_start']));
            $sMsg = sprintf(
                $this->sFormat,
                $iNbEventsPerSec,
                $aData['lap_nb_events'],
                $aData['total_nb_events']
            );
            $aData['lap_start'] = $fNow;
            $aData['lap_end'] += $aData['lap_duration'] * ceil(($fNow - $aData['lap_end']) / $aData['lap_duration']);
            $aData['lap_nb_events'] = 0;
        } else {
            $sMsg = '';
        }

        return $sMsg;
    }
public function doTic()
    {
        $aData = &$this->aData;
        $fNow = microtime(true);

        if ($fNow >= $aData['lap_end'] || $this->isTimeLimitExceeded()) {
            $iNbEventsPerSec = round($aData['lap_nb_events'] / ($fNow - $aData['lap_start']));
            $sMsg = sprintf(
                $this->sFormat,
                $iNbEventsPerSec,
                $aData['lap_nb_events'],
                $aData['total_nb_events']
            );
            $aData['lap_start'] = $fNow;
            $aData['lap_end'] += $aData['lap_duration'] * ceil(($fNow - $aData['lap_end']) / $aData['lap_duration']);
            $aData['lap_nb_events'] = 0;
        } else {
            $sMsg = '';
        }

        return $sMsg;
    }
public function doTic ( ) { $ aData = & $ this -> aData ; $ fNow = microtime ( true ) ; if ( $ fNow >= $ aData [ 'lap_end' ] || $ this -> isTimeLimitExceeded ( ) ) { $ iNbEventsPerSec = round ( $ aData [ 'lap_nb_events' ] / ( $ fNow - $ aData [ 'lap_start' ] ) ) ; $ sMsg = sprintf ( $ this -> sFormat , $ iNbEventsPerSec , $ aData [ 'lap_nb_events' ] , $ aData [ 'total_nb_events' ] ) ; $ aData [ 'lap_start' ] = $ fNow ; $ aData [ 'lap_end' ] += $ aData [ 'lap_duration' ] * ceil ( ( $ fNow - $ aData [ 'lap_end' ] ) / $ aData [ 'lap_duration' ] ) ; $ aData [ 'lap_nb_events' ] = 0 ; } else { $ sMsg = '' ; } return $ sMsg ; }
Display stats about number of processed events since last display.
Display stats about number of processed events since last display .