\Framework\AttributesValidate

Summary

Methods
Properties
Constants
__construct()
getMiddleware()
$validator
$scene
$batch
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Properties

$validator

$validator : string

Type

string

$scene

$scene : ?string

Type

?string

$batch

$batch : bool

Type

bool

Methods

__construct()

__construct(string  $validator, string|null  $scene = null, bool  $batch = false) : mixed

Parameters

string $validator

验证器类名 (需继承 Framework\Validation\Validate)

string|null $scene

验证场景 (可选)

bool $batch

是否批量验证 (默认为false,一旦出错立即返回)

Returns

mixed —

getMiddleware()

getMiddleware() : string|string[]

返回该注解关联的中间件类名 (或类名数组)

Returns

string|string[] —