Benchmark::Benchmark_Iterate
Purpose:
Benchmarking
Example: a) require_once 'Benchmark/Iterate.php'; $benchmark = new Benchmark_Iterate;
function foo($string) { print $string . '
'; }
$benchmark->run(100, 'foo', 'test'); $result = $benchmark->get();
b) require_once 'Benchmark/Iterate.php'; $benchmark = new Benchmark_Iterate;
class myclass{
function foo($string) { print $string . '
'; } }
$benchmark->run(100, 'myclass::foo', 'test'); $result = $benchmark->get();
c) require_once 'Benchmark/Iterate.php'; $benchmark = new Benchmark_Iterate;
class myclass{
function foo($string) { print $string . '
'; } }
$myobj = new myclass();
$benchmark->run(100, 'myobj->foo', 'test'); $result = $benchmark->get();
Located in /libraries/pear/Benchmark/Iterate.php (line 74)
PEAR | --Benchmark_Timer | --Benchmark_Iterate
Inherited from Benchmark_Timer
Benchmark_Timer::$auto
Benchmark_Timer::$markers
Benchmark_Timer::$strlen_max
Returns benchmark result.
$result[x ] = execution time of iteration x $result['mean' ] = mean execution time $result['iterations'] = number of iterations
Benchmarks a function.
Inherited From Benchmark_Timer
Benchmark_Timer::Benchmark_Timer()
Benchmark_Timer::display()
Benchmark_Timer::getOutput()
Benchmark_Timer::getProfiling()
Benchmark_Timer::setMarker()
Benchmark_Timer::start()
Benchmark_Timer::stop()
Benchmark_Timer::timeElapsed()
Benchmark_Timer::_Benchmark_Timer()
Documentation generated on Thu, 20 Jan 2005 17:10:10 +0000 by phpDocumentor 1.3.0RC3