public static function findSourceFiles(string $path)
    {
        $result = array();
        $reader = dir($path);

        while ($file = $reader->read())
        {
            if ($file === '.' || $file === '..')
                continue;

            $file = $path . '/' . $file;
            if (substr($file, -4) === ".php")
            {
                $result[] = $file;
            }
            elseif (is_dir($file))
            {
                $sub = self::findSourceFiles($file);
                foreach ($sub as $f)
                    $result[] = $f;
            }
        }

        return $result;
    }