diff options
| author | Daniel Weipert <git@mail.dweipert.de> | 2026-04-14 16:33:04 +0200 |
|---|---|---|
| committer | Daniel Weipert <git@mail.dweipert.de> | 2026-04-14 16:33:04 +0200 |
| commit | f3202403339e94f0186b9ff19e83c7a32fdad198 (patch) | |
| tree | c3310b1f456f12a7a92f51948d9c8caf94f11032 /src/App.php | |
| parent | 875b9ece501de5937993c41a83c44f8ea59897d0 (diff) | |
Diffstat (limited to 'src/App.php')
| -rw-r--r-- | src/App.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/App.php b/src/App.php index 33f71ef..e2376b1 100644 --- a/src/App.php +++ b/src/App.php @@ -6,8 +6,12 @@ use Symfony\Component\Dotenv\Dotenv; class App { + private static float $executionStartTime; + public function __construct() { + self::$executionStartTime = microtime(true); + $dotenv = new Dotenv(); $dotenv->load(dirname(__DIR__) . "/.env"); } @@ -16,4 +20,9 @@ class App { Router::getInstance()->run()->send(); } + + public static function getExectionTime(): float + { + return microtime(true) - self::$executionStartTime; + } } |
