class
Illuminate
/
Routing
/
SortedMiddleware
SortedMiddleware
Extends
-
Illuminate\...\Collection
Methods
public
__construct ( array $priorityMap , $middlewares ) : void
Create a new Sorted Middleware container.
Parameters
- $priorityMap array
- $middlewares Illuminate\...\Collection|array
protected
sortMiddleware ( $priorityMap , $middlewares ) : array
Sort the middlewares by the given priority map.
Parameters
- $priorityMap array
- $middlewares array
protected
priorityMapIndex ( $priorityMap , $middleware ) : int|null
Calculate the priority map index of the middleware.
Parameters
- $priorityMap array
- $middleware string
protected
middlewareNames ( $middleware ) : Generator
Resolve the middleware names to look for in the priority array.
Parameters
- $middleware string
protected
moveMiddleware ( $middlewares , $from , $to ) : array
Splice a middleware into a new position and remove the old entry.
Parameters
- $middlewares array
- $from int
- $to int