cxj / php-interval-timers
Manage elapsed one or more elapsed time timers
Installs: 40
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/cxj/php-interval-timers
Requires
- php: >=5.1
Requires (Dev)
- phpunit/phpunit: ^7
This package is auto-updated.
Last update: 2025-09-08 11:43:15 UTC
README
A class to manage one or more elapsed-time timers, for such things as performance metrics.
Installation and Autoloading
This package is installable and PSR-4 autoloadable via Composer as cxj/php-interval-timers.
Alternatively, download a release,
or clone this repository, then map the
Cxj\
namespace to the package src/
directory.
Dependencies
This package requires PHP 5.1 or later. We recommend using the latest available version of PHP as a matter of principle.
Quality
Example Usage
<?php include "vendor/autoload.php"; $timer = new Cxj\Timers; $name = "sample timer"; $timer->start($name); usleep(1000); $r1 = $timer->read($name); echo "$r1 seconds have passed since timer was started" . PHP_EOL;