FormDataRequest
- Full name:
\Codefy\Framework\Http\Request\FormDataRequest - Parent class:
\Codefy\Framework\Http\Request\FormRequest - This class is an Abstract class
Methods
passedValidation
Throws:
Inherited methods
validateResolved
Validate the class instance.
Throws:
prepareForValidation
Prepare the data for validation.
getValidatorInstance
Get the validator instance for the request.
Throws:
passedValidation
Handle a passed validation attempt.
passesAuthorization
Determine if the request passes the authorization check.
failedValidation
Handle a failed validation attempt.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$message | ?string | |
$code | int |
Throws:
failedAuthorization
Throws:
all
Return all input data as an array.
only
Replace internal data with only the specified keys.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$keys | array |
except
Replace internal data excluding the specified keys.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$keys | array |
validated
Validate the request data and return validated data.
value
Return validated or filtered value.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$value | mixed | |
$default | mixed |
messages
Get custom messages for validator errors.
makeValidator
Get the validator instance for the request.
Throws:
createDefaultValidator
Create the default validator instance.
protected createDefaultValidator(\Qubus\Validation\Factories\ValidationFactory $factory): \Qubus\Validation\Validation
Parameters:
| Parameter | Type | Description |
|---|---|---|
$factory | \Qubus\Validation\Factories\ValidationFactory |
Throws:
setValidator
Set the Validator instance.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$validator | \Qubus\Validation\Validation |
setContainer
Set the container implementation.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$container | \Qubus\Injector\ServiceContainer |
errors
Return validation errors.
validationRules
Get the validation rules for this form request.