Egg::Util::BenchMark - Easy bench mark class for Egg.
my $bench= Egg::Util::BenchMark->new($e); $bench->stock('start'); $bench->stock('run'); $bench->stock('end'); $bench->finish; # ¥×¥í¥¸¥§¥¯¥È¤«¤é»È¤¦¤Ê¤é $e->bench('start'); $e->bench('run'); $e->bench('end');
It is an easy bench mark class used with Debaccmord of Egg.
Egg takes the bench mark at each the following method calls while operating by debug mode.
_prepare
_dispatch
_action_start
_action_end
_finalize
_output
_finish
And, it totals at the end and the report is output by $e->debug_out.
In addition, $e->bench(LABEL_STRING) comes to be reported about the application to take the bench mark in detail including the result when putting it at every step.
When debug mode becomes invalid, arranged $e->bench need not be especially excluded because it is changed to the method of not doing anything.
This module is set up by Egg::Util::Debug. To use other bench mark classes, it is set to environment variable EGG_BENCH_CLASS.
Constructor.
my $bench= Egg::Util::BenchMark->new;
The bench mark when called is recorded.
$bench->stock('start'); $bench->stock('end');
The data recorded by stock is totaled and the report is returned.
print STDERR $bench->finish;
Egg::Release, Egg::Util::Debug, Time::HiRes,
Masatoshi Mizuno <lushe@cpan.org>
Copyright (C) 2008 Bee Flag, Corp. <http://egg.bomcity.com/>.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available.
1 POD Error
The following errors were encountered while parsing the POD:
Non-ASCII character seen before =encoding in '¥×¥í¥¸¥§¥¯¥È¤«¤é»È¤¦¤Ê¤é'. Assuming CP1252
To install Egg::Release, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Egg::Release
CPAN shell
perl -MCPAN -e shell install Egg::Release
For more information on module installation, please visit the detailed CPAN module installation guide.