File tree 2 files changed +20
-0
lines changed
2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -538,6 +538,8 @@ with the ``property_info`` service in the Symfony Framework::
538
538
// Type information.
539
539
$doctrineExtractor->getTypes($class, $property);
540
540
541
+ .. _components-property-information-constructor-extractor :
542
+
541
543
ConstructorExtractor
542
544
~~~~~~~~~~~~~~~~~~~~
543
545
@@ -570,6 +572,7 @@ Creating Your Own Extractors
570
572
571
573
You can create your own property information extractors by creating a
572
574
class that implements one or more of the following interfaces:
575
+ :class: `Symfony\\ Component\\ PropertyInfo\\ ConstructorArgumentTypeExtractorInterface `,
573
576
:class: `Symfony\\ Component\\ PropertyInfo\\ PropertyAccessExtractorInterface `,
574
577
:class: `Symfony\\ Component\\ PropertyInfo\\ PropertyDescriptionExtractorInterface `,
575
578
:class: `Symfony\\ Component\\ PropertyInfo\\ PropertyListExtractorInterface `,
@@ -587,6 +590,11 @@ service by defining it as a service with one or more of the following
587
590
* ``property_info.access_extractor `` if it provides access information.
588
591
* ``property_info.initializable_extractor `` if it provides initializable information
589
592
(it checks if a property can be initialized through the constructor).
593
+ * ``property_info.constructor_extractor `` if it provides type information from the constructor argument.
594
+
595
+ .. versionadded :: 7.3
596
+
597
+ The ``property_info.constructor_extractor `` tag was introduced in Symfony 7.3.
590
598
591
599
.. _`PSR-1` : https://www.php-fig.org/psr/psr-1/
592
600
.. _`phpDocumentor Reflection` : https://github.com/phpDocumentor/ReflectionDocBlock
Original file line number Diff line number Diff line change @@ -2451,6 +2451,18 @@ enabled
2451
2451
2452
2452
**type **: ``boolean `` **default **: ``true `` or ``false `` depending on your installation
2453
2453
2454
+ with_constructor_extractor
2455
+ ..........................
2456
+
2457
+ **type **: ``boolean `` **default **: ``false ``
2458
+
2459
+ Configures the ``property_info `` service to extract property information from the constructor arguments
2460
+ using the :ref: `ConstructorExtractor <components-property-information-constructor-extractor >`.
2461
+
2462
+ .. versionadded :: 7.3
2463
+
2464
+ The ``with_constructor_extractor `` option was introduced in Symfony 7.3.
2465
+
2454
2466
rate_limiter
2455
2467
~~~~~~~~~~~~
2456
2468
You can’t perform that action at this time.
0 commit comments