edbizarro / timer
Measure execution time of your code
Installs: 8 781
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 1
Forks: 0
Open Issues: 1
Requires
- php: ^7.1.3
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.12
- orchestra/testbench: ^3.6
- phpunit/phpunit: ^7
This package is auto-updated.
Last update: 2024-11-05 05:49:42 UTC
README
Timer - measure execution time of your code
Here are a few examples on how you can use the package:
use Edbizarro\Timer\Timer; $timer = Timer::start('timer01'); sleep(2); $result = $timer->stop(); print_r($result); // array:7 [ // "start" => 1529506852.084 // "end" => 1529506854.0855 // "duration" => 2.0015239715576 // "milliseconds" => 2001.5239715576 // "seconds" => 2 // "minutes" => 0 // "hours" => 0 // ]
Installation
You can install the package via composer:
composer require edbizarro/timer