HttpService

Implements \HttpServiceInterface

Class HttpService

category

System

package

Http

implements

HttpServiceInterface

Methods

Initializes the http service.

__construct(\AbstractHttpContextFactory $httpContextFactory, \HttpDispatcherInterface $httpDispatcher) 

Arguments

$httpContextFactory

\AbstractHttpContextFactory

Factory instance to create context objects.

$httpDispatcher

\HttpDispatcherInterface

Instance to dispatch the http response message.

Creates and returns a new instance of an http context object.

getHttpContext() : \HttpContextInterface

Handles the current http request by the given context.

handle(\HttpContextInterface $httpContext) 

Arguments

$httpContext

\HttpContextInterface

Context object which holds information about the current request.

Properties

httpContextFactory

httpContextFactory : \AbstractHttpContextFactory

httpDispatcher

httpDispatcher : \HttpDispatcherInterface