Zend\Stratigility\Dispatch::isNotInteropMiddleware PHP Метод

isNotInteropMiddleware() приватный Метод

Test if the middleware composed by a route is not http-interop middleware.
private isNotInteropMiddleware ( mixed $handler, Psr\Http\Message\RequestInterface $request ) : boolean
$handler mixed
$request Psr\Http\Message\RequestInterface
Результат boolean
    private function isNotInteropMiddleware($handler, RequestInterface $request)
    {
        if ($handler instanceof ServerMiddlewareInterface) {
            return false;
        }
        if (!$this->responsePrototype) {
            throw new Exception\MissingResponsePrototypeException('Invoking callable middleware following http-interop middleware, ' . 'but no response prototype is present; please inject one in your ' . 'MiddlewarePipe or ensure Stratigility callable middleware exists ' . 'in the outer layer of your application.');
        }
        if (!$request instanceof ServerRequestInterface) {
            throw new Exception\InvalidRequestTypeException('Invoking callable middleware following http-interop middleware, ' . 'but a server request was not provided.');
        }
        return true;
    }