You are here

public static function ResponseInterface::create in RESTful 7.2

Factory.

Parameters

mixed $content: The response content, see setContent()

int $status: The response status code

array $headers: An array of response headers

Return value

ResponseInterface The created object.

Throws

UnprocessableEntityException When the HTTP status code is not valid

1 method overrides ResponseInterface::create()
Response::create in src/Http/Response.php
Factory.

File

src/Http/ResponseInterface.php, line 31
Contains \Drupal\restful\Http\ResponseInterface.

Class

ResponseInterface

Namespace

Drupal\restful\Http

Code

public static function create($content = '', $status = 200, $headers = array());