protected function DataProvider::setHttpHeader in RESTful 7.2
Sets an HTTP header.
Parameters
string $name: The header name.
string $value: The header value.
3 calls to DataProvider::setHttpHeader()
- DataProviderDbQuery::remove in src/
Plugin/ resource/ DataProvider/ DataProviderDbQuery.php - Delete operation.
- DataProviderEntity::remove in src/
Plugin/ resource/ DataProvider/ DataProviderEntity.php - Delete operation.
- DataProviderEntity::update in src/
Plugin/ resource/ DataProvider/ DataProviderEntity.php - Update operation.
File
- src/
Plugin/ resource/ DataProvider/ DataProvider.php, line 527 - Contains \Drupal\restful\Plugin\resource\DataProvider\DataProvider.
Class
Namespace
Drupal\restful\Plugin\resource\DataProviderCode
protected function setHttpHeader($name, $value) {
$this
->getRequest()
->getHeaders()
->add(HttpHeader::create($name, $value));
}