minor #40786 [Serializer][Validator] Update some phpDoc relative to "getters" (guilliamxavier)

This PR was squashed before being merged into the 4.4 branch.

Discussion
----------

[Serializer][Validator] Update some phpDoc relative to "getters"

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yesish (phpDoc unaccurate after code updates)
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

Commits
-------

5046500deb [Serializer][Validator] Update some phpDoc relative to "getters"
This commit is contained in:
Fabien Potencier 2021-04-13 08:32:45 +02:00
commit 3f42c08abd
3 changed files with 4 additions and 4 deletions

View File

@ -61,7 +61,7 @@ class GetSetMethodNormalizer extends AbstractObjectNormalizer
}
/**
* Checks if the given class has any get{Property} method.
* Checks if the given class has any getter method.
*/
private function supports(string $class): bool
{
@ -77,7 +77,7 @@ class GetSetMethodNormalizer extends AbstractObjectNormalizer
}
/**
* Checks if a method's name is get.* or is.*, and can be called without parameters.
* Checks if a method's name matches /^(get|is|has).+$/ and can be called non-statically without parameters.
*/
private function isGetMethod(\ReflectionMethod $method): bool
{

View File

@ -237,7 +237,7 @@ class ClassMetadata extends GenericMetadata implements ClassMetadataInterface
* Adds a constraint to the getter of the given property.
*
* The name of the getter is assumed to be the name of the property with an
* uppercased first letter and either the prefix "get" or "is".
* uppercased first letter and the prefix "get", "is" or "has".
*
* @param string $property The name of the property
*

View File

@ -18,7 +18,7 @@ use Symfony\Component\Validator\Exception\ValidatorException;
* method.
*
* A property getter is any method that is equal to the property's name,
* prefixed with either "get" or "is". That method will be used to access the
* prefixed with "get", "is" or "has". That method will be used to access the
* property's value.
*
* The getter will be invoked by reflection, so the access of private and