ValidationCollector
extends Collector
in package
Class ValidationCollector.
Table of Contents
- $activities : array<string|int, mixed>
- $data : array<string|int, mixed>
- $name : string
- $validation : Validation
- $validatorsRules : array<string|int, mixed>
- __construct() : mixed
- addData() : static
- getActivities() : array<int, array<string, mixed>>
- getContents() : string
- getData() : array<string|int, mixed>
- getName() : string
- getSafeName() : string
- hasData() : bool
- setErrorInDebugData() : static
- setValidation() : static
- getValidatorsRules() : array<string, array<string, mixed>>
- renderRuleset() : string
- renderValidations() : string
- renderValidatorsRules() : string
- sRule() : string
Properties
$activities
protected
array<string|int, mixed>
$activities
= []
$data
protected
array<string|int, mixed>
$data
= []
$name
protected
string
$name
$validation
protected
Validation
$validation
$validatorsRules
protected
array<string|int, mixed>
$validatorsRules
Methods
__construct()
public
__construct([string $name = 'default' ]) : mixed
Parameters
- $name : string = 'default'
Return values
mixed —addData()
public
addData(array<string|int, mixed> $data) : static
Parameters
- $data : array<string|int, mixed>
Return values
static —getActivities()
public
getActivities() : array<int, array<string, mixed>>
Return values
array<int, array<string, mixed>> —getContents()
public
getContents() : string
Return values
string —getData()
public
getData() : array<string|int, mixed>
Return values
array<string|int, mixed> —getName()
public
getName() : string
Return values
string —getSafeName()
public
getSafeName() : string
Return values
string —hasData()
public
hasData() : bool
Return values
bool —setErrorInDebugData()
public
setErrorInDebugData(string $field, string $error[, int $index = -1 ]) : static
Parameters
- $field : string
- $error : string
- $index : int = -1
Return values
static —setValidation()
public
setValidation(Validation $validation) : static
Parameters
- $validation : Validation
Return values
static —getValidatorsRules()
protected
getValidatorsRules() : array<string, array<string, mixed>>
Return values
array<string, array<string, mixed>> —renderRuleset()
protected
renderRuleset() : string
Return values
string —renderValidations()
protected
renderValidations() : string
Return values
string —renderValidatorsRules()
protected
renderValidatorsRules() : string
Return values
string —sRule()
protected
sRule(string $rule, array<string, mixed> $validatorsRules) : string
Parameters
- $rule : string
- $validatorsRules : array<string, mixed>