MicroKernelTrait
trait MicroKernelTrait
A Kernel that provides configuration hooks.
Methods
Details
abstract protected
configureRoutes(RouteCollectionBuilder $routes)
Add or import routes into your application.
$routes->import('config/routing.yml'); $routes->add('/admin', 'App\Controller\AdminController::dashboard', 'admin_dashboard');
abstract protected
configureContainer(ContainerBuilder $c, LoaderInterface $loader)
Configures the container.
You can register extensions:
$c->loadFromExtension('framework', array(
'secret' => '%secret%'
));
Or services:
$c->register('halloween', 'FooBundle\HalloweenProvider');
Or parameters:
$c->setParameter('halloween', 'lot of fun');