HTTP response builder interface.
More...
HTTP response builder interface.
Definition at line 13 of file ResponseBuilder.php.
Elgg\Http\ResponseBuilder::getContent |
( |
| ) |
|
Elgg\Http\ResponseBuilder::getException |
( |
| ) |
|
Elgg\Http\ResponseBuilder::getForwardURL |
( |
| ) |
|
Returns redirect URL.
- Returns
- string|null string the forward url, null when no url was set or the constant REFERRER
Implemented in Elgg\Http\Response.
Elgg\Http\ResponseBuilder::getHeaders |
( |
| ) |
|
Elgg\Http\ResponseBuilder::getStatusCode |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isClientError |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isInformational |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isNotModified |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isOk |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isRedirection |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isServerError |
( |
| ) |
|
Elgg\Http\ResponseBuilder::isSuccessful |
( |
| ) |
|
Elgg\Http\ResponseBuilder::setContent |
( |
|
$content = '' | ) |
|
Sets response body.
- Parameters
-
mixed | $content | Content of the response as a scalar value or an array |
- Returns
- self
- Exceptions
-
Implemented in Elgg\Http\Response.
Elgg\Http\ResponseBuilder::setException |
( |
\Exception |
$e | ) |
|
Set an exception for this response.
- Parameters
-
\Exception | $e | the exception for this response |
- Returns
- self
Implemented in Elgg\Http\Response.
Elgg\Http\ResponseBuilder::setForwardURL |
( |
string |
$forward_url = REFERRER | ) |
|
Elgg\Http\ResponseBuilder::setHeaders |
( |
array |
$headers = [] | ) |
|
Sets additional response headers.
- Parameters
-
- Returns
- self
Implemented in Elgg\Http\Response.
Elgg\Http\ResponseBuilder::setStatusCode |
( |
int |
$status_code | ) |
|
Sets response HTTP status code.
- Parameters
-
int | $status_code | Status code |
- Returns
- self
- Exceptions
-
Implemented in Elgg\Http\Response.
The documentation for this interface was generated from the following file: