2017 © Pedro Peláez
 

library timer

Basic script timers

image

muzzlefork/timer

Basic script timers

  • Monday, July 29, 2013
  • by MuzzleFork
  • Repository
  • 1 Watchers
  • 0 Stars
  • 6 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

muzzlefork/timers

Basic composer package for PHP allowing you to time actions., (*1)

Installation: composer require "muzzlefork/timer 0.1.*", (*2)

Usage:, (*3)

$t = MuzzleFork\Timer::get('x'); // Timers are inactive when started
$t->resume('Starting API call');
// do some heavy work
$t->pause('API command completed');
// go and do something else
$t->resume('Starting new API call');
$t->pause('Some other message');

echo $t->getTotal();

Of note:, (*4)

  • When you create a timer, it is inactive, so you should ->start() or ->resume() it.
  • You can pass a message to ->resume($msg) and ->pause($msg) which can be handy when getting the full list out.

The Versions

29/07 2013

dev-master

9999999-dev

Basic script timers

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

by Lucas Eagleton

29/07 2013

v0.1.0

0.1.0.0

Basic script timers

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

by Lucas Eagleton