Return the controller class names by controllers (without validate if the class exists)

@param string $controller The name of controller
@return array
552120
public function getControllerClasses($controller)
    {
        $classes = array();

        // Prepare parameters for replacing
        $controller = strtr($controller, array('/' => '\\'));

        if ($this->controllerFormat) {
            // Generate class from format
            $namespace = $this->getNamespace();
            $class = str_replace(
                array('%namespace%', '%controller%'),
                array(ucfirst($namespace), ucfirst($controller)),
                $this->controllerFormat
            );

            // Make the class name's first letter uppercase
            $upperLetter = strrpos($class, '\\') + 1;
            $class[$upperLetter] = strtoupper($class[$upperLetter]);
            $classes[] = $class;
        }

        // Add class from predefined classes
        if (isset($this->controllerMap[$controller])) {
            $classes[] = $this->controllerMap[$controller];
        }

        return $classes;
    }
59258
private function models($controller)
    {
        $properties = $controller::$properties;
        $module = $this->name($controller);

        $models = [];

        foreach ((array) U::array_value($properties, 'models') as $model) {
            $modelClassName = '\\app\\'.$module.'\\models\\'.$model;

            $info = $modelClassName::metadata();

            $models[ $model ] = array_replace($info, [
                'route_base' => '/'.$module.'/'.$info[ 'plural_key' ], ]);
        }

        return $models;
    }
374598
private function getAttributeName(callable $controller)
    {
        list($object, $name) = $controller;
        $method = new \ReflectionMethod($object, $name);
        foreach ($method->getParameters() as $param) {
            if ($this->isParamFetcherType($param)) {
                return $param->getName();
            }
        }

        // If there is no typehint, inject the ParamFetcher using a default name.
        return 'paramFetcher';
    }
918017
private function getParameters(Request $request, \ReflectionFunctionAbstract $controller) : array
    {
        if ($controller instanceof \ReflectionMethod) {
            $annotations = $this->annotationReader->getMethodAnnotations($controller);
        } else {
            // @todo annotation reading on generic functions is not available yet
            return [];
        }

        $parameters = [];
        foreach ($controller->getParameters() as $parameter) {
            $parameters[$parameter->getName()] = $parameter;
        }

        $result = [];

        foreach ($annotations as $annotation) {
            if ($annotation instanceof RequestParam) {
                $result[$annotation->getBindTo()] = $this->getParameter(
                    $annotation,
                    $controller,
                    $parameters,
                    $request
                );
            }
        }

        return $result;
    }
391637
protected function getController($controller)
	{
		$stub = $this->files->get(__DIR__.'/stubs/controller.stub');

		// We will explode out the controller name on the naemspace delimiter so we
		// are able to replace a namespace in this stub file. If no namespace is
		// provided we'll just clear out the namespace place-holder locations.
		$segments = explode('\\', $controller);

		$stub = $this->replaceNamespace($segments, $stub);

		return str_replace('{{class}}', last($segments), $stub);
	}
582491
private function getClassAndMethod(string $controller)
    {
        if (!isset($this->controllers[$controller])) {
            $this->controllers[$controller] = $this->detectClassAndMethod($controller);
        }

        return $this->controllers[$controller];
    }
1277313
protected function getControllerPrefix(ReflectionClass $controller)
    {
        preg_match("~\@prefix\s([a-zA-Z\\\_]+)~i", (string) $controller->getDocComment(), $prefix);
        return isset($prefix[1]) ? $prefix[1] : str_replace("controller", "", strtolower($controller->getShortName()));
    }
722532
protected function _getArgumentNames($controller, $command)
    {
        $controllerClassName = $this->_getControllerClassName($controller);
        if (!class_exists($controllerClassName)) {
            return [];
        }

        $command = Text::camelize($command) . 'Command';
        if (!method_exists($controllerClassName, $command)) {
            return [];
        }

        $arguments = [];
        foreach ((new \ReflectionMethod($controllerClassName, $command))->getParameters() as $parameter) {
            $arguments[] = '--' . strtr($parameter->name, '_', '-');
        }

        return $arguments;
    }
1322961
public function controller($controller)
    {

        // Instantiate a string controller
        if (is_string($controller)
            && class_exists($controller)
            && is_subclass_of($controller, 'Bkwld\Decoy\Controllers\Base')) {
            $this->controller_name = $controller;
            $this->controller = new $controller;

            // Apply the parent if one was set
            if ($this->parent_item && $this->controller) {
                $this->controller->parent($this->parent_item);
            }

        // Or, validate a passed controller instance
        } elseif (is_object($controller)
            && is_a($controller, 'Bkwld\Decoy\Controllers\Base')) {
            $this->controller_name = get_class($controller);
            $this->controller = $controller;
        }

        // Chain
        return $this;
    }
1360523
private function getPropertyDefinitionConfig($controller)
    {
        $injectableDefinitions = $this->getPropertyDefinition();

        return $this->setPropertyInjection($injectableDefinitions)
             ->getDefinitions($controller);
    }
757173
private function getControllerClassName() : string
    {
        $tableName = App::shortName(get_class($this->table), 'Model/Table', 'Table');

        return (string)App::className($tableName . 'Controller', 'Controller');
    }
1137044
public function slugController($controller)
    {
        // Get the controller name
        $controller = preg_replace('#^('.preg_quote('Bkwld\Decoy\Controllers\\')
            .'|'.preg_quote('App\Http\Controllers\Admin\\').')#', '', $controller);

        // Convert study caps to dashes
        $controller = Str::snake($controller, '-');

        // Done
        return $controller;
    }
889562
protected function parseParameters(array $parameters, $controller) {
        if(!isset($parameters['uses']) || $parameters['uses'] === null) {
            if($controller === null) {
                throw new InvalidArgumentException('No `uses` key provided for Action');
            } else {
                $parameters['uses'] = $controller . '@' . $parameters['name'];
            }
        }

        return $parameters;
    }
37755
protected function isSkipController(string $controller): bool
    {
        if (in_array($controller, $this->getSkipControllers())) {
            return true;
        }

        return false;
    }
980186
protected function getControllerMiddlewareFromInstance($controller, $method)
    {
        $middlewares = $this->router->getMiddleware();

        //
        $results = array();

        foreach ($controller->getMiddleware() as $middleware => $options) {
            if (ControllerDispatcher::methodExcludedByOptions($method, $options)) {
                continue;
            }

            list($name, $parameters) = array_pad(explode(':', $middleware, 2), 2, null);

            $middleware = Arr::get($middlewares, $name, $name);

            $results[] = (! $middleware instanceof Closure) ? $middleware : $name;
        }

        return $results;
    }
1142310
private function getControllerLocator($controller)
    {
        $class = null;
        $prefix = null;

        if (0 === strpos($controller, '@')) {
            $file = $this->locator->locate($controller);
            $controllerClass = ClassUtils::findClassInFile($file);

            if (false === $controllerClass) {
                throw new \InvalidArgumentException(sprintf('Can\'t find class for controller "%s"', $controller));
            }

            $controller = $controllerClass;
        }

        if ($this->container->has($controller)) {
            // service_id
            $prefix = $controller.':';

            if (Kernel::VERSION_ID >= 40100) {
                $prefix .= ':';
            }

            $useScope = method_exists($this->container, 'enterScope') && $this->container->hasScope('request');
            if ($useScope) {
                $this->container->enterScope('request');
                $this->container->set('request', new Request());
            }
            $class = get_class($this->container->get($controller));
            if ($useScope) {
                $this->container->leaveScope('request');
            }
        } elseif (class_exists($controller)) {
            // full class name
            $class = $controller;
            $prefix = $class.'::';
        } elseif (false !== strpos($controller, ':')) {
            // bundle:controller notation
            try {
                $notation = $this->controllerParser->parse($controller.':method');
                list($class) = explode('::', $notation);
                $prefix = $class.'::';
            } catch (\Exception $e) {
                throw new \InvalidArgumentException(
                    sprintf('Can\'t locate "%s" controller.', $controller)
                );
            }
        }

        if (empty($class)) {
            throw new \InvalidArgumentException(sprintf(
                'Class could not be determined for Controller identified by "%s".', $controller
            ));
        }

        return [$prefix, $class];
    }
574460
protected function makeController($controller)
	{
		Controller::setFilterer($this->filterer);

		return $this->container->make($controller);
	}