PAGI\Node\NodeController::registerResult PHP Method

registerResult() public method

Registers a new node result to be taken into account when the given node is ran.
public registerResult ( string $name ) : NodeActionCommand
$name string
return NodeActionCommand
    public function registerResult($name)
    {
        $nodeActionCommand = new NodeActionCommand();
        if (!isset($this->nodeResults[$name])) {
            $this->nodeResults[$name] = array();
        }
        $this->nodeResults[$name][] = $nodeActionCommand;
        return $nodeActionCommand->whenNode($name);
    }