Archived
1
0
Fork 0
This repository has been archived on 2026-05-10. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
fiktivkod/library/Fiktiv/Performance.php
2010-09-15 19:06:54 +02:00

39 lines
No EOL
587 B
PHP

<?php
class Fiktiv_Performance
{
/**
* @var float
*/
protected static $_start = null;
/**
* @var float
*/
protected static $_end = null;
/**
* @return void
*/
public static function begin()
{
self::$_start = microtime(true);
}
/**
* @return float
*/
public static function end()
{
self::$_end = microtime(true);
return self::results();
}
/**
* @return float
*/
public static function results()
{
return self::$_end - self::$_start;
}
}