Add the given info to the current plan's results.

@see base_plan::add_result()
@param array $result associative array describing a result of a task/step
320804
public function add_result($result) {
        if (!is_null($this->plan)) {
            $this->plan->add_result($result);
        } else {
            debugging('Attempting to add a result of a task not binded with a plan', DEBUG_DEVELOPER);
        }
    }
868290
protected function addMethod(array $result, $method) {
		// We must exclude all find...By... patterns as possible false positives for now (refs https://github.com/cakephp/cakephp/issues/11240)
		if ($method === 'findOrCreate' || preg_match('/^find.*By[A-Z][a-zA-Z]+/', $method)) {
			return $result;
		}
		if (!preg_match('/^find([A-Z][a-zA-Z]+)/', $method, $matches)) {
			return $result;
		}

		$result[] = lcfirst($matches[1]);

		sort($result);

		return $result;
	}
265780
protected function finishAddOrderCheckout(array $result)
    {
        if (!empty($result['order']['order_id'])) {

            $vars = array(
                '@num' => $result['order']['order_id'],
                '@name' => $result['order']['customer_name'],
                '@status' => $this->order->getStatusName($result['order']['status'])
            );

            $message = $this->text('Order #@num has been created for user @name. Order status: @status', $vars);
            $this->redirect("admin/sale/order/{$result['order']['order_id']}", $message, 'success');
        }
    }
1161553
public function setResult($result = self::RESULT_SUCCESS,
                              $message = null,
                              array $data = [],
                              array $additional = [])
    {
        $this->headers->set('X-Phlexible-Response', 'result');

        $values = [
            'success' => $result,
            'msg' => $message,
            'data' => $data,
        ];

        if (is_array($additional) && count($additional)) {
            foreach ($additional as $key => $value) {
                $values += $additional;
            }
        }

        $this->setData($values);
    }
176052
public function buildResult($result)
    {
        $chatMembers = [];

        foreach ($result as $item) {
            $chatMembers[] = new ChatMember($item);
        }

        return $chatMembers;
    }
56176
protected function transformResult(array $result)
    {
        if ($this->columnTransformers->count()) {
            foreach ($result as $index => $row) {
                $result[$index] = $this->transformRow($row);
            }
        }
        
        return $result;
    }
1175329
protected function succeed($result = null)
    {
        $this->isFinished = true;
        $this->isSuccess = true;
        $this->result = $result;
    }
158352
public function finish(string $name, array $result = null)
    {
        if ($this->enabled && $this->has($name)) {
            $this->getSwoole()->finish([
                'name' => $name,
                'result' => $result
            ]);
        }
    }
836648
public function addOutcome(OutcomeDeclaration $outcome){
        $this->outcomes[$outcome->getSerial()] = $outcome;
        $outcome->setRelatedItem($this);
    }
1179965
private function maybeAppendWithKey(string $key, array &$result, array $values): void
    {
        if ([] !== $values) {
            $result[$key] = $values;
        }
    }
6631
protected function finishActionModule($result)
    {
        if ($result === true) {
            $this->redirect('', $this->text('Module has been updated'), 'success');
        }

        $message = $result ? $result : $this->text('Operation unavailable');
        $this->redirect('', $message, 'danger');
    }
1364771
protected function handleResult(array $result)
    {
        if ($this->onlyCount && isset($result[0]) && is_array($result[0])) {
            return (int)current($result[0]);
        }

        $entities = [];
        foreach ($result as $row) {
            $model = clone $this->getModel();
            $model->populate($row);
            $entities[] = $model;
        }
        return $entities;
    }
654860
public function addData(array $result): array
    {
        if ($result['tableName'] === 'sys_redirect' && isset($result['processedTca']['columns']['source_host'])) {
            $domains = $this->getHosts();
            foreach ($domains as $domain) {
                $result['processedTca']['columns']['source_host']['config']['valuePicker']['items'][] =
                    [
                        $domain,
                        $domain,
                    ];
            }
        }
        return $result;
    }
590530
protected function processResult($result)
    {
        $output = Helper::objectToArray($result);

        if (! is_array($output)) {
            throw new Error\Api($output);
        }

        if (isset($output['result'])) {
            return $output;
        }

        if (
            isset($output['request']) &&
            $output['request']['result'] != 1 &&
            $output['request']['result'] !== 'TRUE') {
            throw new Error\Api($output['request']['errorId'] . ' - ' . $output['request']['errorMessage']);
        }

        return $output;
    }
864785
public static function addResultAtIndex(Result $result, $index)
    {
        // Add result
        $results = static::getResults();
        $results[$index] = $result;

        // Store results
        static::setResults($results);
    }
930305
protected function populateResult()
    {
        // default: mark that the processor completed succesfully
        $this->result->setSuccess(true);

        // store output array in result data
        $this->result->output = $this->context->output;
    }
351337
public function setResult($result = null)
    {
        $this->result = $result;
        $this->state = self::STATE_DONE;
        if ($this->listeners) {
            $this->listeners->executeAll($this->result);
        }
    }