diff --git a/pfosten/app/MyClasses/TimeLogger.php b/pfosten/app/MyClasses/TimeLogger.php new file mode 100644 index 00000000..86b9bbf7 --- /dev/null +++ b/pfosten/app/MyClasses/TimeLogger.php @@ -0,0 +1,23 @@ +startTime = microtime(true); + $this->functionName =$_functionName; + $this->pkey="".rand(1000,9999); + } + + public function getStartMessage() { + return "[CLOCK] [".$this->pkey."-".$this->functionName."] [started]"; + } + + public function getEndMessage() { + return "[CLOCK] [".$this->pkey."-". $this->functionName."] [ended] [elapsed: ".number_format( ( microtime(true) - $this->startTime), 4)."]"; + } +} \ No newline at end of file