ControllerNameParser
in package
ControllerNameParser converts controller from the short notation a:b:c (BlogBundle:Post:index) to a fully-qualified class::method string (Bundle\BlogBundle\Controller\PostController::indexAction).
Tags
Table of Contents
- $kernel : mixed
- __construct() : mixed
- build() : string
- Converts a class::method notation to a short one (a:b:c).
- parse() : string
- Converts a short notation a:b:c to a class::method.
- findAlternative() : string|null
- Attempts to find a bundle that is *similar* to the given bundle name.
Properties
$kernel
protected
mixed
$kernel
Methods
__construct()
public
__construct(KernelInterface $kernel[, bool $triggerDeprecation = true ]) : mixed
Parameters
- $kernel : KernelInterface
- $triggerDeprecation : bool = true
Return values
mixed —build()
Converts a class::method notation to a short one (a:b:c).
public
build(string $controller) : string
Parameters
- $controller : string
-
A string in the class::method notation
Tags
Return values
string —A short notation controller (a:b:c)
parse()
Converts a short notation a:b:c to a class::method.
public
parse(string $controller) : string
Parameters
- $controller : string
-
A short notation controller (a:b:c)
Tags
Return values
string —A string in the class::method notation
findAlternative()
Attempts to find a bundle that is *similar* to the given bundle name.
private
findAlternative(string $nonExistentBundleName) : string|null
Parameters
- $nonExistentBundleName : string