protected function EntityShareServerRestAbstract::setError in Entity Share 7
Set the error of the action.
Parameters
string $error: The potential error to set.
string $status: The http error status.
Return value
EntityShareServerRestAbstract The current class instance.
6 calls to EntityShareServerRestAbstract::setError()
- EntityShareServerRest::handleDelete in modules/
entity_share_server/ includes/ entity_share_server.rest.inc - Handle the DELETE method action.
- EntityShareServerRest::handleGet in modules/
entity_share_server/ includes/ entity_share_server.rest.inc - Handle the GET method action.
- EntityShareServerRest::handlePost in modules/
entity_share_server/ includes/ entity_share_server.rest.inc - Handle the POST method action.
- EntityShareServerRestAbstract::doLogin in modules/
entity_share_server/ includes/ entity_share_server.rest.abstract.inc - Authenticate the user.
- EntityShareServerRestAbstract::handle in modules/
entity_share_server/ includes/ entity_share_server.rest.abstract.inc - Handle the server.
File
- modules/
entity_share_server/ includes/ entity_share_server.rest.abstract.inc, line 145 - Class for handling Entity Share Rest Server request.
Class
- EntityShareServerRestAbstract
- Abstract Class to manage the EntityShare Rest server.
Code
protected function setError($error, $status = '400 Bad Request') {
$this->error = $error;
$this
->setHeader('Status', $status);
return $this;
}