Files
kiri-core/Annotation/RequestValidator.php
T
2021-03-03 18:35:04 +08:00

38 lines
498 B
PHP

<?php
namespace Annotation;
use Exception;
use validator\Validator;
/**
* Class RequestValidator
* @package Annotation
*/
#[\Attribute(\Attribute::TARGET_METHOD)] class RequestValidator extends Attribute
{
/**
* RequestValidator constructor.
* @param array $validators
* @throws Exception
*/
public function __construct(public array $validators)
{
}
/**
* @param array $handler
* @return bool
*/
public function execute(array $handler): bool
{
return true;
}
}