ValidateFieldsSubscriber
extends AbstractPrepareSubscriber
in package
Validate field inputs based on annotations in the action class
Tags
Table of Contents
Methods
- checkType() : bool
- Validate variable type on input
- getSubscribedEvents() : array<string|int, mixed>
- onApiPrepare() : mixed
Methods
checkType()
Validate variable type on input
public
static checkType(mixed $value, mixed $types) : bool
Parameters
- $value : mixed
- $types : mixed
Tags
Return values
boolgetSubscribedEvents()
public
static getSubscribedEvents() : array<string|int, mixed>
Return values
array<string|int, mixed>onApiPrepare()
public
onApiPrepare(PrepareEvent $event) : mixed
Parameters
- $event : PrepareEvent