trait ValidatesWhenResolvedTrait

Provides default implementation of ValidatesWhenResolved contract.

Methods

void
validateResolved()

Validate the class instance.

void
prepareForValidation()

Prepare the data for validation.

getValidatorInstance()

Get the validator instance for the request.

void
passedValidation()

Handle a passed validation attempt.

void
failedValidation(Validator $validator)

Handle a failed validation attempt.

bool
passesAuthorization()

Determine if the request passes the authorization check.

void
failedAuthorization()

Handle a failed authorization attempt.

Details

at line 17
void validateResolved()

Validate the class instance.

Return Value

void

at line 41
protected void prepareForValidation()

Prepare the data for validation.

Return Value

void

at line 48
protected Validator getValidatorInstance()

Get the validator instance for the request.

Return Value

Validator

at line 56
protected void passedValidation()

Handle a passed validation attempt.

Return Value

void

at line 65
protected void failedValidation(Validator $validator)

Handle a failed validation attempt.

Parameters

Validator $validator

Return Value

void

Exceptions

ValidationException

at line 75
protected bool passesAuthorization()

Determine if the request passes the authorization check.

Return Value

bool

at line 89
protected void failedAuthorization()

Handle a failed authorization attempt.

Return Value

void

Exceptions

UnauthorizedException