original_string: public function complete($result)
      {
          $this->finished = true;
          $this->result = $result;
  
          if (!count($this->callback[self::TASK_COMPLETE])) {
              return;
          }
  
          foreach ($this->callback[self::TASK_COMPLETE] as $callback) {
              call_user_func($callback, $this->func, $this->handle, $result);
          }
      }
code: public function complete($result)
      {
          $this->finished = true;
          $this->result = $result;
  
          if (!count($this->callback[self::TASK_COMPLETE])) {
              return;
          }
  
          foreach ($this->callback[self::TASK_COMPLETE] as $callback) {
              call_user_func($callback, $this->func, $this->handle, $result);
          }
      }
code_tokens: public function complete ( $ result ) { $ this -> finished = true ; $ this -> result = $ result ; if ( ! count ( $ this -> callback [ self :: TASK_COMPLETE ] ) ) { return ; } foreach ( $ this -> callback [ self :: TASK_COMPLETE ] as $ callback ) { call_user_func ( $ callback , $ this -> func , $ this -> handle , $ result ) ; } }
docstring: Run the complete callbacks.
  
  Complete callbacks are passed the name of the job, the handle of the
  job and the result of the job (in that order).
  
  @param object $result JSON decoded result passed back
  
  @see \MHlavac\Gearman\Task::attachCallback()
docstring_tokens: Run the complete callbacks .