src/Profiler/Profiler.php
/**
	 * measure the elapsed time of a timer without stoping the timer if
	 *
	 * @param string $name
	 * @return float
	 */
measure the elapsed time of a timer without stoping the timer if
@param string $name
@return float
measure the elapsed time of a timer without stoping the timer if @param string $name @return float
public function elapsedTime(string $name): float
	{
		if (!array_key_exists($name, $this->startTime)) {
			return 0;
		}
		if (array_key_exists($name, $this->endTime)) {
			return ($this->endTime[$name] - $this->startTime[$name]);
		}
		else {
			$now = microtime(true);
			return ($now - $this->startTime[$name]);
		}
	}
public function elapsedTime ( string $ name ) : float { if ( ! array_key_exists ( $ name , $ this -> startTime ) ) { return 0 ; } if ( array_key_exists ( $ name , $ this -> endTime ) ) { return ( $ this -> endTime [ $ name ] - $ this -> startTime [ $ name ] ) ; } else { $ now = microtime ( true ) ; return ( $ now - $ this -> startTime [ $ name ] ) ; } }
measure the elapsed time of a timer without stoping the timer if
 @param string $name
 @return float
measure the elapsed time of a timer without stoping the timer if @param string $name @return float
// This shouldn't happen, but it does once.