public function createClass(string $name, string $location, string $extends = "") : bool
    {
        $namespace = trim($this->getNameSpace($name));
        $name = trim($this->getClassName($name));
        $className = $name;

        if ($extends !== "") {
            $className .= " extends {$extends}";
        }

        if ($namespace != "") {
            $namespace = "namespace ".$namespace;
        }

        $class = file_get_contents($this->templates["class.template"]);
        $class = str_replace(["[namespace]","[name]"], [$namespace, $className], $class);

        if (is_dir($location)) {
            file_put_contents($location."/".$name.".php", $class);
            return true;
        }

        return false;
    }