SecurityController
extends AbstractController
in package
Provides common features needed in controllers.
Table of Contents
- $container : ContainerInterface
- getSubscribedServices() : array<string|int, string>
- Returns an array of service types required by such instances, optionally keyed by the service names used internally.
- login() : Response
- logout() : void
- getParameter() : array<string|int, mixed>|bool|float|int|string|null
- Gets a container parameter by its name.
Properties
$container
protected
ContainerInterface
$container
Methods
getSubscribedServices()
Returns an array of service types required by such instances, optionally keyed by the service names used internally.
public
static getSubscribedServices() : array<string|int, string>
For mandatory dependencies:
- ['logger' => 'Psr\Log\LoggerInterface'] means the objects use the "logger" name internally to fetch a service which must implement Psr\Log\LoggerInterface.
- ['loggers' => 'Psr\Log\LoggerInterface[]'] means the objects use the "loggers" name internally to fetch an iterable of Psr\Log\LoggerInterface instances.
- ['Psr\Log\LoggerInterface'] is a shortcut for
- ['Psr\Log\LoggerInterface' => 'Psr\Log\LoggerInterface']
otherwise:
- ['logger' => '?Psr\Log\LoggerInterface'] denotes an optional dependency
- ['loggers' => '?Psr\Log\LoggerInterface[]'] denotes an optional iterable dependency
- ['?Psr\Log\LoggerInterface'] is a shortcut for
- ['Psr\Log\LoggerInterface' => '?Psr\Log\LoggerInterface']
Return values
array<string|int, string> —The required service types, optionally keyed by service names
login()
public
login(AuthenticationUtils $authenticationUtils) : Response
Parameters
- $authenticationUtils : AuthenticationUtils
Tags
Return values
Response —logout()
public
logout() : void
Tags
Return values
void —getParameter()
Gets a container parameter by its name.
protected
getParameter(string $name) : array<string|int, mixed>|bool|float|int|string|null
Parameters
- $name : string