Gets the ReflectionClass instance for this mapped class.

@return \ReflectionClass
771879
public function getReflectionClass()
    {
        if (!$this->refClass) {
            $this->refClass = new \ReflectionClass($this->getName());
        }

        return $this->refClass;
    }
176348
protected function getClass()
    {
        // Retrieve path to Resources and shortname's class
        $class = new \ReflectionClass(get_class($this));

        // Return a simple array
        return [
            'name'      => $class->getShortName(),
            'path'      => $class->getFileName(),
            'resources' => dirname(dirname($class->getFileName())).S.'Resources',
        ];
    }
197585
public function getClass($class)
    {
        $cacheKey = self::CACHE_KEY_CLASSES . strtolower($class);

        if (! $reflectionClass = $this->cache->fetch($cacheKey)) {
            $reflectionClass = new ReflectionClass($class);
            $this->cache->store($cacheKey, $reflectionClass);
        }

        return $reflectionClass;
    }
571825
public function getEntityClass()
    {
        if ($this->entityClass === null) {
            $class = get_class($this);
            $method = 'get' . substr($class, strrpos($class, '\\')+1) . 'EntityClass';
            $this->setEntityClass($this->getOptions()->$method());
        }
        return $this->entityClass;
    }
306601
public function getInstance()
    {
        if ($this->isSingleton() && $this->hasInstance()) {
            return $this->instance;
        }

        // require path
        if ($this->path) {
            require_once $this->path;
        }

        // initialize
        if ($this->isClosure()) {
            $closure = $this->class;
            $instance = $closure($this->container);
        } else {
            $class = $this->class;
            if ($class[0] !== '\\') $class = '\\' . $class;
            $script = sprintf('$instance = new %s(%s);', $class, $this->array2ArgsWithInjectDependency('$this->args', $this->args));
            eval($script);
        }

        if ($this->isSingleton()) {
            $this->instance = $instance;
        }
        if ($this->container && method_exists($instance, 'setContainer')) {
            $instance->setContainer($this->container);
        }
        
        // inject dependency
        if ($this->container) {
            $this->container->injectDependency($instance);
        }
        
        // init method
        if ($this->hasInitMethod()) {
            $this->callInitMethod($instance);
        } elseif($this->hasInitializeMethod($instance)) {
            $instance->initialize();
        }

        return $instance;
    }
675348
public function getBaseClass()
    {
        if ($this->isAlias() && $this->baseClass === null) {
            return $this->alias;
        } elseif ($this->baseClass === null) {
            return $this->getDatabase()->getBaseClass();
        } else {
            return $this->baseClass;
        }
    }
389231
private function ClassFile()
    {
        if (!$this->classFile)
        {
            
            $class = new \ReflectionClass($this);
            $this->classFile = $class->getFileName();
        }
        return $this->classFile;
    }
934649
public function get()
    {
        return $this->findAndLoadClasses()
            ->map(function ($class) {
                return new ReflectionClass($class);
            })
            ->reject(function ($class) {
                return $this->rejectionStrategy->shouldClassBeRejected($class);
            })
            ->reject(function ($class) {
                foreach (config('stats.ignored_namespaces', []) as $namespace) {
                    if (Str::startsWith($class->getNamespaceName(), $namespace)) {
                        return true;
                    }
                }

                return false;
            })
            ->groupBy(function ($class) {
                return (new Classifier)->classify($class);
            });
    }
1333994
final public static function getInstance()
  {
    $className = get_called_class();
    
    if (!isset(self::$_instances[$className])) {
      self::$_instances[$className] = new static();
    }
    self::$_instances[$className]->initialize();

    return self::$_instances[$className];
  }
504965
private function getClassProperties(ReflectionClass $reflectionClass)
    {
        $properties = $reflectionClass->getProperties();

        return array_filter(
            array_filter(array_map(
                [$this, 'getAccessibleProperty'],
                array_combine(
                    array_map([$this, 'getLogicalName'], $properties),
                    $properties
                )
            )),
            [$this, 'isInstanceProperty']
        );
    }
951858
public function getReflectionClass()
    {
        if ($this->reflection) {
            return $this->reflection;
        }

        if (!$this->class) {
            throw new \InvalidArgumentException(
                'Cannot retrieve ReflectionClass on metadata which has no class attribute'
            );
        }

        $this->reflection = new \ReflectionClass($this->class);

        return $this->reflection;
    }
381377
protected static function getResolvedClassInstance()
    {
        $classNamespace = static::getStaticClassAccessor();
        $resolvedClassInstance = self::getClass($classNamespace);
        
        if (! $resolvedClassInstance) {
            return self::resolveClassNameSpace($classNamespace);  
        }

        return $resolvedClassInstance;
    }
983067
protected function getMappingClasses(): array
    {
        AnnotationRegistry::registerLoader('class_exists');

        $mappingClasses = [];

        foreach ($this->locator->getMappingFiles() as $annotationFile) {
            $mappingClasses[] = $this->loadClassFromFile($annotationFile);
        }

        return \array_map(
            function (string $sourceClass) {
                return new \ReflectionClass($sourceClass);
            },
            \array_filter(\array_unique($mappingClasses))
        );
    }
1071348
public function getClassMap() {
		if ($this->classMap) {
			return $this->classMap;
		}

		if ($this->useCache) {
			// Cache duration: 30 minutes.
			$this->classMap = $this->cacheService->get("mouf.classMap.".__DIR__."/".json_encode($this->selfEdit));
			if ($this->classMap != null) {
				return $this->classMap;
			}
		}
		
		$this->analyze();
		return $this->classMap;
	}
514307
final public static function getInstance()
    {
        $className = get_called_class();
        if (!isset(self::$_instances[$className])) {
            $instance = new $className();
            /* @var SingleTon $instance */
            $instance->init();
            self::$_instances[$className] = $instance;
        }
        return self::$_instances[$className];
    }
441971
public static function classes()
    {
        $objs = array();

        foreach (get_declared_classes() as $value) {
            $value = ltrim($value, '\\');
            $cname = new \ReflectionClass($value);

            if (false === $cname->isInternal()) {
                $objs[$value] = $cname->getDefaultProperties();
            }

            $cname = null;
        }

        return $objs;
    }
1257397
private static function instance()
    {
        $currentClass = get_called_class();
        $instanceName = empty( self::$instance ) ? '' : new \ReflectionClass(self::$instance);
        if( empty( self::$instance ) || ( $instanceName->name != $currentClass ) ) {
            self::$instance = new static();
        }
        return self::$instance;
    }