Error message

  • Warning: count(): Parameter must be an array or an object that implements Countable in _api_make_match_member_link() (line 1230 of /home/projects/api/www/sites/all/modules/api/api.formatting.inc).
  • Warning: count(): Parameter must be an array or an object that implements Countable in _api_make_match_member_link() (line 1230 of /home/projects/api/www/sites/all/modules/api/api.formatting.inc).

public function JobItemInterface::setState

Updates the state of the job item.

Parameters

string $state: The new state of the job item. Has to be one of the job state constants.

string $message: (Optional) The log message to be saved along with the state change.

array $variables: (Optional) An array of variables to replace in the message on display.

string $type: (optional) Statically set to status.

Return value

int The updated state of the job item if it could be set.

See also

Job::addMessage()

1 method overrides JobItemInterface::setState()
JobItem::setState in src/Entity/JobItem.php
Updates the state of the job item.

File

src/JobItemInterface.php, line 320

Class

JobItemInterface
Interface for tmgmt_job_item entity.

Namespace

Drupal\tmgmt

Code

public function setState($state, $message = NULL, $variables = array(), $type = 'debug');