You are here

public function BackgroundProcess::setCallback in Background Process 7.2

Set callback and arguments

File

./background_process.inc, line 348
External API short overview

Class

BackgroundProcess
@file

Code

public function setCallback($callback, $arguments = array()) {
  $this
    ->ensureProcess();
  $this->callback = $callback;
  $this->arguments = $arguments;
  $this->dirty['callback'] = serialize($this->callback);
  $this->dirty['arguments'] = serialize($this->arguments);
  $this
    ->logDebug('setCallback' . " {$callback} (" . strlen($this->dirty['arguments']) . " bytes)");
  return $this;
}