/
githubmirror
/
symfony
Обзор
Документация
Войти
/
githubmirror
/
symfony
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
8.2
src/Symfony/Component/Validator/Attribute/ExtendsValidationFor.php
32 строки
784 B
Nicolas Grekas
[Validator] Add `#[ExtendsValidationFor]` to declare new constraints for a class
03 сен 2025, 19:44
03 сен 2025, 19:44
e884a76
Код
Авторство
О чём код?
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Validator\Attribute; /** * Declares that constraints listed on the current class should be added to the given class. * * Classes that use this attribute should contain only properties and methods that * exist on the target class (not necessarily all of them). * * @author Nicolas Grekas <p@tchwork.com> */ #[\Attribute(\Attribute::TARGET_CLASS)] final class ExtendsValidationFor { /** * @param class-string $class */ public function __construct( public string $class, ) { } }