class Validator implements ExtenderInterface

Methods

__construct(string $validatorClass)

No description

configure(callable|class-string $callback)

<p>Configure the validator. This is often used to adjust validation rules, but can be used to make other changes to the validator as well.</p>

extend(Container $container, Extension $extension = null)

No description

Details

__construct(string $validatorClass)

Parameters

string $validatorClass

Validator configure(callable|class-string $callback)

<p>Configure the validator. This is often used to adjust validation rules, but can be used to make other changes to the validator as well.</p>

Parameters

callable|class-string $callback <p>The callback can be a closure or invokable class, and should accept:</p> <ul> <li>\Flarum\Foundation\AbstractValidator $flarumValidator: The Flarum validator wrapper</li> <li>\Illuminate\Validation\Validator $validator: The Laravel validator instance</li> </ul> <p>The callback should return void.</p>

Return Value

Validator

extend(Container $container, Extension $extension = null)

Parameters

Container $container
Extension $extension