You are here

public static function ProcessFormExtra::batchOperation in Module Builder 8.3

Implements callback_batch_operation().

Overrides ProcessForm::batchOperation

File

module_builder_devel/src/Form/ProcessFormExtra.php, line 16

Class

ProcessFormExtra
Replaces the code analysis form to add message about time taken.

Namespace

Drupal\module_builder_devel\Form

Code

public static function batchOperation($job_batch, &$context) {

  // Store the start time the first time this operation runs.
  if (!isset($context['results']['start_time'])) {
    $context['results']['start_time'] = \Drupal::time()
      ->getRequestTime();
  }
  parent::batchOperation($job_batch, $context);
}