\Brickrouge\ValidatorRegExValidator

Validates one or multiple regular expressions.

Summary

Methods
Properties
Constants
__construct()
__invoke()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$pattern
$message
N/A

Properties

$pattern

$pattern : string|array

Type

string|array

$message

$message : string

Type

string

Methods

__construct()

__construct(string|array  $pattern, string  $message) 

Parameters

string|array $pattern
string $message

__invoke()

__invoke(\ICanBoogie\Errors  $errors, \Brickrouge\Element  $element, mixed  $value) : boolean

Validates the value provided.

Parameters

\ICanBoogie\Errors $errors

Used to collect error messages.

\Brickrouge\Element $element

Target element.

mixed $value

The value to validate.

Returns

boolean —

true if the value is valid, false otherwise.