public function enable($rootNamespace = self::ROOT_NAMESPACE_GLOBAL)
    {
        // If XStatic is already enabled, this is a no-op
        if ($this->aliasLoader->isRegistered()) {
            return true;
        }

        // Register the loader to handle aliases and link the proxies to the container
        if ($this->aliasLoader->register($rootNamespace)) {
            StaticProxy::setContainer($this->container);
        }

        return $this->aliasLoader->isRegistered();
    }
public function enable($rootNamespace = self::ROOT_NAMESPACE_GLOBAL)
    {
        // If XStatic is already enabled, this is a no-op
        if ($this->aliasLoader->isRegistered()) {
            return true;
        }

        // Register the loader to handle aliases and link the proxies to the container
        if ($this->aliasLoader->register($rootNamespace)) {
            StaticProxy::setContainer($this->container);
        }

        return $this->aliasLoader->isRegistered();
    }
public function enable ( $ rootNamespace = self :: ROOT_NAMESPACE_GLOBAL ) { // If XStatic is already enabled, this is a no-op if ( $ this -> aliasLoader -> isRegistered ( ) ) { return true ; } // Register the loader to handle aliases and link the proxies to the container if ( $ this -> aliasLoader -> register ( $ rootNamespace ) ) { StaticProxy :: setContainer ( $ this -> container ) ; } return $ this -> aliasLoader -> isRegistered ( ) ; }
Enables the Static Proxies by injecting the Container object and registering the Alias Loader for autoloading

@param bool|string $rootNamespace The namespace that the alias should be created in

@return bool
@see \XStatic\AliasLoaderInterface::register()
Enables the Static Proxies by injecting the Container object and registering the Alias Loader for autoloading