@@ -12,10 +12,13 @@ in order to be recognized. This is done via the
12
12
creating and registering custom argument value resolvers, you can extend this
13
13
functionality.
14
14
15
- Functionality Shipped with the HttpKernel
16
- -----------------------------------------
15
+ .. _functionality-shipped-with-the-httpkernel :
17
16
18
- Symfony ships with the following value resolvers in the HttpKernel component:
17
+ Built-In Value Resolvers
18
+ ------------------------
19
+
20
+ Symfony ships with the following value resolvers in the
21
+ :doc: `HttpKernel component </components/http_kernel >`:
19
22
20
23
:class: `Symfony\\ Component\\ HttpKernel\\ Controller\\ ArgumentResolver\\ RequestAttributeValueResolver `
21
24
Attempts to find a request attribute that matches the name of the argument.
@@ -42,21 +45,18 @@ Symfony ships with the following value resolvers in the HttpKernel component:
42
45
argument list. When the action is called, the last (variadic) argument will
43
46
contain all the values of this array.
44
47
45
- Functionality Shipped with Additional Bundles
46
- ---------------------------------------------
47
-
48
- The SecurityBundle:
48
+ In addition, some official bundles provide other value resolvers:
49
49
50
50
:class: `Symfony\\ Bundle\\ SecurityBundle\\ SecurityUserValueResolver `
51
- Injects the user object of the current logged in user if type-hinted
51
+ Injects the object that represents the current logged in user if type-hinted
52
52
with ``UserInterface ``. Default value can be set to ``null `` in case
53
- the controller can be accessed by non logged in users.
54
-
55
- The SensioFrameworkExtraBundle:
53
+ the controller can be accessed by anonymous users. It requires installing
54
+ the `SecurityBundle `_.
56
55
57
56
``Psr7ServerRequestResolver ``
58
- Injects a PSR-7 compliant version of the current request if type-hinted with
59
- ``RequestInterface ``, ``MessageInterface `` or ``ServerRequestInterface ``.
57
+ Injects a `PSR-7 `_ compliant version of the current request if type-hinted
58
+ with ``RequestInterface ``, ``MessageInterface `` or ``ServerRequestInterface ``.
59
+ It requires installing the `SensioFrameworkExtraBundle `_.
60
60
61
61
Adding a Custom Value Resolver
62
62
------------------------------
@@ -249,3 +249,6 @@ subrequests.
249
249
250
250
.. _`@ParamConverter` : https://symfony.com/doc/current/bundles/SensioFrameworkExtraBundle/annotations/converters.html
251
251
.. _`yield` : http://php.net/manual/en/language.generators.syntax.php
252
+ .. _`SecurityBundle` : https://github.com/symfony/security-bundle
253
+ .. _`PSR-7` : https://www.php-fig.org/psr/psr-7/
254
+ .. _`SensioFrameworkExtraBundle` : https://github.com/sensiolabs/SensioFrameworkExtraBundle
0 commit comments