Menu

## MiddlewareRegistry
in package

MiddlewareRegistry.php : 8

### Table of Contents

$allowGlobalMiddleware : bool
$isInitialized : bool
$layers : array<string|int, mixed>
__construct() : mixed
init() : MiddlewareRegistry
process() : mixed
toArray() : array<string|int, mixed>
createCoreFunction() : Closure
createLayer() : Closure
loadMiddleware() : array<string|int, mixed>

### Properties

#### $allowGlobalMiddleware

MiddlewareRegistry.php : 15
`public bool $allowGlobalMiddleware`

#### $isInitialized

MiddlewareRegistry.php : 13
`public bool $isInitialized = false`

#### $layers

MiddlewareRegistry.php : 11
`private array<string|int, mixed> $layers`

### Methods

#### __construct()

MiddlewareRegistry.php : 42
`public __construct([array<string|int, mixed> $layers = [] ][, mixed $allowGlobal = true ]) : mixed`

##### Parameters

$layers : array<string|int, mixed> = []
$allowGlobal : mixed = true

##### Return values

mixed —

#### init()

MiddlewareRegistry.php : 48
`public init([mixed $routeMiddlewareLayers = [] ][, mixed $cancelGlobal = false ]) : MiddlewareRegistry`

##### Parameters

$routeMiddlewareLayers : mixed = []
$cancelGlobal : mixed = false

##### Return values

MiddlewareRegistry —

#### process()

MiddlewareRegistry.php : 75
`public process(WebRequest $request, Closure $core) : mixed`

##### Parameters

$request : WebRequest
$core : Closure

##### Return values

mixed —

#### toArray()

MiddlewareRegistry.php : 90
`public toArray() : array<string|int, mixed>`

##### Return values

array<string|int, mixed> —

#### createCoreFunction()

MiddlewareRegistry.php : 28
`private createCoreFunction(Closure $core) : Closure`

##### Parameters

$core : Closure

##### Return values

Closure —

#### createLayer()

MiddlewareRegistry.php : 35
`private createLayer(mixed $nextLayer, mixed $layer) : Closure`

##### Parameters

$nextLayer : mixed
$layer : mixed

##### Return values

Closure —

#### loadMiddleware()

MiddlewareRegistry.php : 17
`private loadMiddleware(array<string|int, mixed> $array) : array<string|int, mixed>`

##### Parameters

$array : array<string|int, mixed>

##### Return values

array<string|int, mixed> —

## Search results