You are here

protected function ViewsBulkOperationsActionProcessor::setActionContext in Views Bulk Operations (VBO) 8.3

Same name and namespace in other branches
  1. 8 src/Service/ViewsBulkOperationsActionProcessor.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsActionProcessor::setActionContext()
  2. 8.2 src/Service/ViewsBulkOperationsActionProcessor.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsActionProcessor::setActionContext()
  3. 4.0.x src/Service/ViewsBulkOperationsActionProcessor.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsActionProcessor::setActionContext()

Set action context if action method exists.

Parameters

array $context: The context to be set.

2 calls to ViewsBulkOperationsActionProcessor::setActionContext()
ViewsBulkOperationsActionProcessor::initialize in src/Service/ViewsBulkOperationsActionProcessor.php
Set values.
ViewsBulkOperationsActionProcessor::populateQueue in src/Service/ViewsBulkOperationsActionProcessor.php
Populate entity queue for processing.

File

src/Service/ViewsBulkOperationsActionProcessor.php, line 411

Class

ViewsBulkOperationsActionProcessor
Defines VBO action processor.

Namespace

Drupal\views_bulk_operations\Service

Code

protected function setActionContext(array $context) {
  if (isset($this->action) && method_exists($this->action, 'setContext')) {
    $this->action
      ->setContext($context);
  }
}