Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/eusonlito/timer
A simple timer mark script
https://github.com/eusonlito/timer
Last synced: 6 days ago
JSON representation
A simple timer mark script
- Host: GitHub
- URL: https://github.com/eusonlito/timer
- Owner: eusonlito
- Created: 2012-08-22T13:30:18.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2012-08-22T13:37:11.000Z (about 12 years ago)
- Last Synced: 2024-10-18T04:23:05.287Z (26 days ago)
- Language: PHP
- Size: 85.9 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Timer
=====This script works as simple timer control to your app
Usage
--------
mark('Starting a mark previous to operations');foreach ($alotofoperations as $operation) {
$Timer->mark('Start operation '.$operation->name);$operation->function();
$Timer->mark('End operation '.$operation->name);
}$Timer->mark('Ended a mark previous to operations');
foreach ($Timer->get() as $timer) {
echo "\n".sprintf('%01.6f', $timer['total']).' - '.$timer['text'];
}echo "\n".$Timer->getMemoryUsage();