/** * @return array */ private function getParameters() { if ($this->parameters === NULL) { $parameters = ['annotationGroups' => $this->configuration->getOption(CO::ANNOTATION_GROUPS), 'namespace' => NULL, 'package' => NULL, 'class' => NULL, 'constant' => NULL, 'function' => NULL, 'namespaces' => array_keys($this->elementStorage->getNamespaces()), 'packages' => array_keys($this->elementStorage->getPackages()), 'classes' => array_filter($this->elementStorage->getClasses(), $this->getMainFilter()), 'interfaces' => array_filter($this->elementStorage->getInterfaces(), $this->getMainFilter()), 'traits' => array_filter($this->elementStorage->getTraits(), $this->getMainFilter()), 'exceptions' => array_filter($this->elementStorage->getExceptions(), $this->getMainFilter()), 'constants' => array_filter($this->elementStorage->getConstants(), $this->getMainFilter()), 'functions' => array_filter($this->elementStorage->getFunctions(), $this->getMainFilter()), 'elements' => $this->autocompleteElements->getElements()]; if ($this->configuration->getOption(CO::DOWNLOAD)) { $parameters['archive'] = basename($this->configuration->getZipFileName()); } $this->parameters = $parameters; } return $this->parameters; }
/** * @return int */ public function getStepCount() { $tokenizedFilter = function (ReflectionClass $class) { return $class->isTokenized(); }; $count = count(array_filter($this->elementStorage->getClasses(), $tokenizedFilter)) + count(array_filter($this->elementStorage->getInterfaces(), $tokenizedFilter)) + count(array_filter($this->elementStorage->getTraits(), $tokenizedFilter)) + count(array_filter($this->elementStorage->getExceptions(), $tokenizedFilter)) + count($this->elementStorage->getConstants()) + count($this->elementStorage->getFunctions()); return $count; }