public function setMiddlewares(array $middlewares)
    {
        foreach ($middlewares as $middleware) {
            self::validateIsMiddleware($middleware);
        }
        $this->middlewares = $middlewares;
    }
public function setMiddlewares(array $middlewares)
    {
        foreach ($middlewares as $middleware) {
            self::validateIsMiddleware($middleware);
        }
        $this->middlewares = $middlewares;
    }
public function setMiddlewares ( array $ middlewares ) { foreach ( $ middlewares as $ middleware ) { self :: validateIsMiddleware ( $ middleware ) ; } $ this -> middlewares = $ middlewares ; }
Sets middlewares.

@param array $middlewares value.

@return void
Sets middlewares .