jandreasn / a-timer
2.1
2024-03-29 13:18 UTC
Requires
- php: >=8.1
Requires (Dev)
- phpstan/phpstan: ^1.10
- phpunit/phpunit: ^10.0 | ^11.0
- squizlabs/php_codesniffer: ^3.6
This package is auto-updated.
Last update: 2024-03-29 13:25:42 UTC
README
一个简单的计时器,用于对操作进行计时/基准测试,结果简短且易于阅读。
安装
将包添加到您的composer.json
文件中的需求部分
$ composer require andreasnij/a-timer
用法
use ATimer\Timer; $timer = new Timer(); // Some operations that take time echo $timer->getDurationFormatted(); // Example output: 1.237s
作者
Andreas Nilsson (https://github.com/andreasnij)
许可证
在MIT许可证下许可 - 详细信息请参阅LICENSE文件。