Checks if Module is already installed in this application.

@param	string	Name of Module to search.

@return	boolean

@see		PluginInterface::pluginExists()
321109
public static function pluginExists($name) {
	
		$db = Database::getInstance();
		$db->setQuery('SELECT COUNT(1) FROM `modules` WHERE name = ?');
		return (bool)$db->loadCount($name);
	
	}
611600
public function checkIfAliasExists($name){

        if( isset($this->aliases[$name]) ){
            return true;
        }

        $aliasPath = vibius_BASEPATH.$this->aliasCache.$name.".php";
        if( file_exists($aliasPath) ){
            $this->aliases[$name] = true;
            return true;
        }
    }
245511
public function __isset($name)
    {
        if (0 === stripos($name, 'conf_')) {
            $name = str_replace('conf_', '', $name);
            if (array_key_exists($name, $this->configs)) {
                return true;
            }
        }

        return (array_key_exists($name, $this->modules) ||
            array_key_exists($name, $this->globals));
    }
1334417
public function shouldBeIgnored($name) : bool
    {
        foreach ($this->ignores as $regex) {
            if (preg_match($regex, $name)) {
                return true;
            }
        }
        return false;
    }
490130
protected function hasSuffix($name)
    {
        $lenSuffix = strlen($this->suffix);

        $hasSuffix = strlen($name) > $lenSuffix;
        $hasSuffix = $hasSuffix && substr_compare($name, $this->suffix, -$lenSuffix, $lenSuffix, true) == 0;

        return $hasSuffix;
    }
1319495
public function isValid($name)
    {
        return is_string($name) && (preg_match(static::SERVICE_PATTERN, $name) || isset($this->app[$name]));
    }
47896
public function hasGlobalMethod($name)
    {
        return
            isset($this->_appScopeTrait) &&
            isset($this->app->_hookTrait) &&
            $this->app->hookHasCallbacks('global-method-'.$name);
    }
588964
public static function exists($name)
    {
        if(is_integer($name))
        {
            return isset($_SERVER['argv'][$name]);
        }
        else
        {
            return isset(static::$cliArgs[$name]);
        }
    }
653187
public function getModuleByName($name)
    {
        foreach ($this->modules as $module) {
            /* @var $module Module */
            if ($name == $module->getValue()->getName()) {
                return $module;
            }
        }

        return false;
    }
642784
public function hasArgument($name) {
        try {
            $argument = $this->getCommand()->findArgument($name);

            return $argument->hasValue();
        } catch (ArgumentNotFoundException $ex) {}

        return false;
    }
24194
public static function exists( string $name ): bool
	{
		if( $name === "@core" )
		{
			return true;
		}

		try {
			$row = self::getModuleScheme($name, false, ["id"]);
		}
		catch(NotFoundException $e) {
			return false;
		}

		return $row->id > 0;
	}
626243
public function hasExtraConfiguration($name)
    {
        $name = $this->resolveString($name, __METHOD__);

        return isset($this->extraConfiguration[$name]);
    }
1263621
protected function hasImplementedPluginInterface($name)
    {
        $result = false;

        if (class_exists($name)) {
            $implements = class_implements($name);

            if (isset($implements['Yosymfony\\Spress\\Core\\Plugin\\PluginInterface'])) {
                $result = true;
            }
        }

        return $result;
    }
607415
public function findOrFail($name)
    {
        $module = $this->find($name);

        if ($module !== null) {
            return $module;
        }

        throw new ModuleNotFoundException("Module [{$name}] does not exist!");
    }
1218909
public function hasCommand(string $name): bool
	{
		$this->initCommands();

		// If command is already registered, we're good
		if (isset($this->commands[$name]))
		{
			return true;
		}

		// If there is no loader, we can't look for a command there
		if (!$this->commandLoader)
		{
			return false;
		}

		return $this->commandLoader->has($name);
	}
351926
public function uninstallModule($name)
    {
        $return = [];
        if (!($module = CModule::CreateModuleObject($name))) {
            throw new Exception("Module {$name} not found");
        } elseif (!$module->IsInstalled()) {
            throw new Exception("Module {$name} already uninstalled");
        } else {
            $module->DoUninstall();
            $return[] = "Module {$name} uninstalled";
        }

        return $return;
    }
303467
function hasLoaded($moduleName)
    {
        if (!is_string($moduleName))
            throw new \InvalidArgumentException(sprintf(
                'Invalid module name, "%s".'
                , \Poirot\Std\flatten($moduleName)
            ));

        return in_array($moduleName, $this->listLoadedModules());
    }