Returns a MoufXmlReflectionClass representing the class we are going to analyze.

@param string $className
@param boolean $selfEdit
@return MoufXmlReflectionClass
496502
public static function getClass($className, $selfEdit) {
		$url = MoufReflectionProxy::getLocalUrlToProject()."src/direct/get_class.php?class=".$className."&selfedit=".(($selfEdit)?"true":"false");

		$response = self::performRequest($url);
		
		return new MoufXmlReflectionClass($response);
	}
1343981
private function createMethods(ClassReflection $classReflection, ClassReflection $instance): array
    {
        $methods = [];
        foreach ($instance->getNativeReflection()->getMethods(\ReflectionMethod::IS_PUBLIC) as $method) {
            $methods[$method->getName()] = $this->methodReflectionFactory->create(
                $classReflection,
                $method,
                ReflectionMethodAlwaysStatic::class
            );
        }

        return $methods;
    }
1354155
public function getClass()
    {
    	try {
    		$className = $this->getClassName();
    		if ($className == null){
    			return null;
    		}else if (!class_exists($className) && !interface_exists($className) && !trait_exists($className)){
	    		throw new MoufException("Error while analyzing @param annotation for parameter {$this->paramName} in '{$this->getDeclaringClass()->getName()}::{$this->getDeclaringFunction()->getName()}': class '$className' could not be found");
    		}
	        $refClass = parent::getClass();
	        if (null === $refClass) {
	            return null;
	        }
    	} catch (\ReflectionException $e) {
    		throw new MoufException("Error while analyzing @param annotation for parameter {$this->paramName} in '{$this->getDeclaringClass()->getName()}::{$this->getDeclaringFunction()->getName()}': ".$e->getMessage(), 0, $e);
    	}
        
        $moufRefClass = new MoufReflectionClass($refClass->getName());
        return $moufRefClass;
    }
603684
protected final function getReflection(string $className): ReflectionClass
   {
       try {
           $reflexion = new ReflectionClass($className);
       } catch (ReflectionException $e) {
           throw new NotFoundException(
               "Can't get reflection for " . $className . ": not found");
       }
       if (!$reflexion->isInstantiable()) {
           throw new ContainerException(
               "Can't get reflection for " . $className . ": not instanciable");
       }
       return $reflexion;
   }
1192318
public function getClassDescriptor($className) {
		if (!isset($this->classDescriptors[$className])) {
			if (MoufManager::getMoufManager() == null || (MoufManager::getMoufManager()->getScope() == self::SCOPE_APP && $this->getScope() == self::SCOPE_APP)
					|| (MoufManager::getMoufManager()->getScope() == self::SCOPE_ADMIN && $this->getScope() == self::SCOPE_ADMIN)) {
				// We are fully in the scope of the application:
				$this->classDescriptors[$className] = new MoufReflectionClass($className);
			} else {
				$this->classDescriptors[$className] = MoufReflectionProxy::getClass($className, $this->getScope() == self::SCOPE_ADMIN);
			}
		}
		return $this->classDescriptors[$className];
	}
415946
public static function getInstance(
        $classname, $input = "", $userDefFunction = null
    ) {
        $fullname = "soloproyectos\\css\\parser\\filter\\"
            . $classname;
        return new $fullname($input, $userDefFunction);
    }
571845
public function isMethodProtected($className, $methodName)
    {
        $className = $this->prepareClassReflectionForUsage($className);
        return (isset($this->classReflectionData[$className][self::DATA_CLASS_METHODS][$methodName][self::DATA_METHOD_VISIBILITY]) && $this->classReflectionData[$className][self::DATA_CLASS_METHODS][$methodName][self::DATA_METHOD_VISIBILITY] === self::VISIBILITY_PROTECTED);
    }
700390
public function deleteInstance($selfedit = "false", $instanceName=null, $returnurl = null) {
        $this->selfedit = $selfedit;

        if ($selfedit == "true") {
            $this->moufManager = MoufManager::getMoufManager();
        } else {
            $this->moufManager = MoufManager::getMoufManagerHiddenInstance();
        }

        $this->moufManager->removeComponent($instanceName);
        $this->moufManager->rewriteMouf();

        if ($returnurl) {
            header("Location:".$returnurl);
        } else {
            header("Location: .?selfedit=".$selfedit);
        }
    }
1180844
protected function getReflectionClass($className) {
		if (isset($this->reflectionClasses[$className])) {
			return $this->reflectionClasses[$className];
		}

		try {
			$reflectionClass = new ReflectionClass($className);
		} catch (ReflectionException $e) {
			throw new NotFoundException("Class $className is not found");
		}

		if (!$reflectionClass->isInstantiable()) {
			throw new NotInstantiableException("$className is not an instantiable class");
		}

		$this->reflectionClasses[$className] = $reflectionClass;

		return $reflectionClass;
	}
105532
public function writeHtAccess($selfedit = 'false')
    {
        if ($selfedit == 'true') {
            $moufManager = MoufManager::getMoufManager();
        } else {
            $moufManager = MoufManager::getMoufManagerHiddenInstance();
        }

        $this->exludeExtentions = $moufManager->getVariable('splashexludeextentions');
        $this->exludeFolders = $moufManager->getVariable('splashexludefolders');
        if (empty($this->exludeExtentions)) {
            $this->exludeExtentions = array('js', 'ico', 'gif', 'jpg', 'png', 'css', 'woff', 'ttf', 'svg', 'eot', 'map');
        }
        if (empty($this->exludeFolders)) {
            $this->exludeFolders = array('vendor');
        }

        $this->splashGenerateService->writeHtAccess($this->exludeExtentions, $this->exludeFolders);

        InstallUtils::continueInstall($selfedit == 'true');
    }
932842
public function index($name, $selfedit = false) {
		$this->initController($name, $selfedit);

		$this->template->getWebLibraryManager()->addLibrary(new WebLibrary(["vendor/mouf/javascript.ace/src-min-noconflict/ace.js"]));
		
		$this->contentBlock->addFile(dirname(__FILE__)."/../../views/instances/viewInstance.php", $this);
		$this->rightBlock->addText("<div id='instanceList'></div>");
		$this->template->toHtml();	
	}
46350
static function classInspect( $classname )
    {
        if ( !class_exists( $classname ) )
        {
            eZDebug::writeError( "Cannot introspect class $classname for wsdl generation: class not found", __METHOD__ );
            return array();
        }
        $classmethods = get_class_methods( $classname );
        if ( in_array( "attributes", $classmethods ) && in_array( "attribute", $classmethods ) )
        {
            // 'template object' (should be a descendant of ezpo)
            $out = array();
            if ( is_callable( 'ezPODocScanner::definition' ) )
            {
                // load theorical desc parsed from online docs. A warning is logged by ezPODocScanner if class is not found
                $defs = ezPODocScanner::definition( strtolower( $classname ) );
                if ( isset( $defs['attributes'] ) )
                {
                    foreach( $defs['attributes'] as $name => $attr )
                    {
                        if ( strpos( $attr['type'], 'object [' ) === 0 )
                        {
                            $typename = substr( $attr['type'], 8, -1 );
                            // currently we get lowercase class names, but we want correct casing
                            // (add strtolower in case in the future ezPODocScanner is fixed)
                            $typename = ezPODocScanner::findClassNameGivenLowerCaseName( strtolower( $typename ) );
                            $out[$name] = $typename;
                        }
                        else if ( strpos( $attr['type'], 'array [' ) === 0 )
                        {
                            $typename = substr( $attr['type'], 7, -1 );
                            if ( !ezPODocScanner::isscalar( $typename ) && $typename != 'array' )
                            {
                                $typename = ezPODocScanner::findClassNameGivenLowerCaseName( strtolower( $typename ) );
                            }
                            $out[$name] = 'array of ' . $typename;
                        }
                        else
                        {
                            $out[$name] = $attr['type'];
                        }
                    }
                }
            }
            else
            {
                eZDebug::writeError( "Cannot introspect subclass of eZPO for wsdl generation ($classname): missing extension ezpersistentobject_inspector", __METHOD__ );
            }
            return $out;
        }
        else
        {
            // not a template class: do a dump based on reflection
            $out = array();
            $reflectionClass = new ReflectionClass( $classname );
            foreach( $reflectionClass->getProperties( ReflectionProperty::IS_PUBLIC | ReflectionProperty::IS_STATIC ) as $prop )
            {
                $doc = $prop->getDocComment();
                $type = $doc == '' ? 'mixed' : self::typeFromDocComment( $doc );
                $out[$prop->name] = $type;
            }
            return $out;
        }
    }
1032221
public static function fromReflection(ReflectionMethod $reflectionMethod)
    {
        $method = new static($reflectionMethod->getName());
        foreach ($reflectionMethod->getParameters() as $parameter) {
            $method->addParameter(ParameterGenerator::fromReflection($parameter));
        }

        $method->setFinal($reflectionMethod->isFinal());
        $method->setAbstract($reflectionMethod->isAbstract());

        if ($reflectionMethod->isStatic() === true) {
            $method->setStatic(true);
        }

        if ($reflectionMethod->isPrivate() === true) {
            $method->setVisibility(Modifiers::VISIBILITY_PRIVATE);
        } elseif ($reflectionMethod->isProtected() === true) {
            $method->setVisibility(Modifiers::VISIBILITY_PROTECTED);
        } else {
            $method->setVisibility(Modifiers::VISIBILITY_PUBLIC);
        }

        if ($reflectionMethod->getReflectionDocComment()->isEmpty() !== true) {
            $method->setDocumentation(
                DocCommentGenerator::fromReflection($reflectionMethod->getReflectionDocComment())
            );
        }

        if ($reflectionMethod->isAbstract() !== true) {
            $body = trim($reflectionMethod->getBody());
            if ($body !== '') {
                $method->setBody($body);
            }
        }

        return $method;
    }
1222561
public static function getConfigConstants($selfEdit) {

		$url = MoufReflectionProxy::getLocalUrlToProject()."src/direct/get_defined_constants.php?selfedit=".(($selfEdit)?"true":"false");
		
		$response = self::performRequest($url);

		$obj = @unserialize($response);
		
		if ($obj === false) {
			throw new Exception("Unable to unserialize message:\n".$response."\n<br/>URL in error: <a href='".plainstring_to_htmlprotected($url)."'>".plainstring_to_htmlprotected($url)."</a>");
		}
		
		return $obj;
	}
771879
public function getReflectionClass()
    {
        if (!$this->refClass) {
            $this->refClass = new \ReflectionClass($this->getName());
        }

        return $this->refClass;
    }
907174
public function getMethodId($context_self = null)
    {
        if ($this->function instanceof ClassMethod) {
            $function_name = (string)$this->function->name;

            return ($context_self ?: $this->source->getFQCLN()) . '::' . strtolower($function_name);
        }

        if ($this->function instanceof Function_) {
            $namespace = $this->source->getNamespace();

            return ($namespace ? strtolower($namespace) . '\\' : '') . strtolower($this->function->name->name);
        }

        return $this->getFilePath()
            . ':' . $this->function->getLine()
            . ':' . (int)$this->function->getAttribute('startFilePos')
            . ':-:closure';
    }
1248779
public function configure($selfedit = 'false')
    {
        $this->selfedit = $selfedit;

        if ($selfedit == 'true') {
            $this->moufManager = MoufManager::getMoufManager();
        } else {
            $this->moufManager = MoufManager::getMoufManagerHiddenInstance();
        }

        $classNameMapper = ClassNameMapper::createFromComposerFile(__DIR__.'/../../../../../../../../../composer.json');
        $namespaces = $classNameMapper->getManagedNamespaces();
        if ($namespaces) {
            $rootNamespace = $namespaces[0];
        } else {
            set_user_message('<strong>Warning</strong> : Mouf could not find a PSR-0 or PSR-4 autoloader configured
                in your composer.json file. Therefore, unless you are using your own autoloader, it is likely that mouf will be unable to find the Splash Controllers.
                <br/>You should :
                <ol>
                    <li><a href="http://getcomposer.org/doc/04-schema.md#psr-0" target="_blank">Configure PSR-4 in your composer.json</a></li>
                    <li>Regenerate your composer autoloader : <pre>php composer.phar dumpautoload</pre></li>
                    <li>Refresh this page</li>
                </ol>');
            $rootNamespace = '';
        }

        $this->controllerNamespace = $this->moufManager->getVariable('splashDefaultControllersNamespace');
        if ($this->controllerNamespace == null) {
            $this->controllerNamespace = $rootNamespace.'Controllers';
        }
        $this->viewDirectory = $this->moufManager->getVariable('splashDefaultViewsDirectory');
        if ($this->viewDirectory == null) {
            $this->viewDirectory = 'views/';
        }

        $this->content->addFile(__DIR__.'/../../../../../views/admin/installStep2.php', $this);
        $this->template->toHtml();
    }