TrimStrings
extends TransformsRequest
in package
Table of Contents
- $attributes : array<string|int, mixed>
- The additional attributes passed to the middleware.
- $except : array<string|int, mixed>
- The attributes that should not be trimmed.
- handle() : mixed
- Handle an incoming request.
- clean() : void
- Clean the request's data.
- cleanArray() : array<string|int, mixed>
- Clean the data in the given array.
- cleanParameterBag() : void
- Clean the data in the parameter bag.
- cleanValue() : mixed
- Clean the given value.
- transform() : mixed
- Transform the given value.
Properties
$attributes
The additional attributes passed to the middleware.
protected
array<string|int, mixed>
$attributes
= []
$except
The attributes that should not be trimmed.
protected
array<string|int, mixed>
$except
= []
Methods
handle()
Handle an incoming request.
public
handle(Request $request, Closure $next, mixed ...$attributes) : mixed
Parameters
- $request : Request
- $next : Closure
- $attributes : mixed
Return values
mixed —clean()
Clean the request's data.
protected
clean(Request $request) : void
Parameters
- $request : Request
Return values
void —cleanArray()
Clean the data in the given array.
protected
cleanArray(array<string|int, mixed> $data) : array<string|int, mixed>
Parameters
- $data : array<string|int, mixed>
Return values
array<string|int, mixed> —cleanParameterBag()
Clean the data in the parameter bag.
protected
cleanParameterBag(ParameterBag $bag) : void
Parameters
- $bag : ParameterBag
Return values
void —cleanValue()
Clean the given value.
protected
cleanValue(string $key, mixed $value) : mixed
Parameters
- $key : string
- $value : mixed
Return values
mixed —transform()
Transform the given value.
protected
transform(string $key, mixed $value) : mixed
Parameters
- $key : string
- $value : mixed