Add a specific processing that will be applied to nodes having the matching name.

@param nodeName
the name of nodes that will be processed.
@param processor
the processor.
18650
public void addProcessor(String nodeName, NodeProcessor processor)
	{
		if (null == processor)
		{
			throw new IllegalArgumentException("Processor should not be null.");
		}
		if (IS_EMPTY.test(nodeName))
		{
			throw new IllegalArgumentException("The node name should not be empty.");
		}
		getActionPool().put(nodeName, processor);
	}
47731
private static void addProcessors(final Processor processor, final String... keys) throws IllegalStateException {
        for (final String key : keys) {
            addProcessor(key, processor);
        }
    }
1185256
@Override
    public Processor newProcessor(Processor sourceProcessor) {
        LocalClustererProcessor newProcessor = new LocalClustererProcessor();
        LocalClustererProcessor originProcessor = (LocalClustererProcessor) sourceProcessor;
        if (originProcessor.getLearner() != null) {
            newProcessor.setLearner(originProcessor.getLearner().create());
        }
        newProcessor.setOutputStream(originProcessor.getOutputStream());
        return newProcessor;
    }
1102126
private void initializeProcessor(JsonProcessor processor) throws ODataUnmarshallingException {
        LOG.info("Trying to initialize processor: {}", processor.getClass().getSimpleName());
        processor.initialize();

        fields = processor.getValues();
        odataValues = processor.getODataValues();
        links = processor.getLinks();
    }
1188710
def add_node(self, node_id, name, labels):
        '''  '''
        if node_id not in self.node_cache:
            self.workbench.add_node(node_id, name, labels)
            self.node_cache.add(node_id)
528609
public function addProcessor(ProcessorInterface $processor)
    {
        $this->processors[] = $processor;
        $this->logDebug('Added processor: ' . get_class($processor));
    }
693244
public void replaceWith(String nodeName) {
		feature = null;
		this.nodeName = nodeName;
		trueNode = falseNode = null;
	}
731565
public void heartbeatNode (String nodeName)
    {
        updatePartial(NodeRecord.getKey(nodeName),
                      NodeRecord.LAST_UPDATED, new Timestamp(System.currentTimeMillis()));
    }
838463
public void addNode(int n)
  {

    if (!m_mutable)
      throw new RuntimeException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_NODESETDTM_NOT_MUTABLE, null)); //"This NodeSetDTM is not mutable!");

    this.addElement(n);
  }
1056557
public void processingInstruction(String target, String data)
        throws SAXException {
        trace("processingInstruction");
        ProcessingInstruction instruction =
            currentDocument.createProcessingInstruction(target, data);
        appendNode(instruction);
    }
977824
public void registerSpecialVariableProcessor(@Nonnull final SpecialVariableProcessor processor) {
    assertNotNull("Processor is null", processor);

    for (final String varName : processor.getVariableNames()) {
      assertNotNull("A Special Var name is null", varName);
      if (mapVariableNameToSpecialVarProcessor.containsKey(varName)) {
        throw new IllegalStateException("There is already defined processor for " + varName);
      }
      mapVariableNameToSpecialVarProcessor.put(varName, processor);
    }
  }
254950
@Override
    public void onNodeAdded(Node node) {
        if (node instanceof RuleSetNode) {
            RuleSetNode ruleSetNode = (RuleSetNode) node;
            String ruleFlowGroup = ruleSetNode.getRuleFlowGroup();
            if (ruleFlowGroup != null) {
                addSharedReference(ruleFlowGroup,
                                   PartType.RULEFLOW_GROUP);
            }
        } else if (node instanceof WorkItemNode) {
            String taskName = ((WorkItemNode) node).getWork().getName();
            addSharedReference(taskName,
                               PartType.TASK_NAME);
        } else if (node instanceof SubProcessNode) {
            SubProcessNode subProcess = (SubProcessNode) node;

            String processName = subProcess.getProcessName();
            if (!StringUtils.isEmpty(processName)) {
                addResourceReference(processName,
                                     ResourceType.BPMN2_NAME);
            }
            String processId = subProcess.getProcessId();
            if (!StringUtils.isEmpty(processId)) {
                addResourceReference(processId,
                                     ResourceType.BPMN2);
            }
        }
    }
309375
public void addNodes(NodeIterator iterator)
  {

    if (!m_mutable)
      throw new RuntimeException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_NODESET_NOT_MUTABLE, null)); //"This NodeSet is not mutable!");

    if (null != iterator)  // defensive to fix a bug that Sanjiva reported.
    {
      Node obj;

      while (null != (obj = iterator.nextNode()))
      {
        addElement(obj);
      }
    }

    // checkDups();
  }
1249459
public void addNode(final @Nonnull Node node) throws IOException {
        Node oldNode = nodes.get(node.getNodeName());
        if (node != oldNode) {
            // TODO we should not need to lock the queue for adding nodes but until we have a way to update the
            // computer list for just the new node
            Queue.withLock(new Runnable() {
                @Override
                public void run() {
                    nodes.put(node.getNodeName(), node);
                    jenkins.updateComputerList();
                    jenkins.trimLabels();
                }
            });
            // TODO there is a theoretical race whereby the node instance is updated/removed after lock release
            try {
                persistNode(node);
            } catch (IOException | RuntimeException e) {
                // JENKINS-50599: If persisting the node throws an exception, we need to remove the node from
                // memory before propagating the exception.
                Queue.withLock(new Runnable() {
                    @Override
                    public void run() {
                        nodes.compute(node.getNodeName(), (ignoredNodeName, ignoredNode) -> oldNode);
                        jenkins.updateComputerList();
                        jenkins.trimLabels();
                    }
                });
                throw e;
            }
            NodeListener.fireOnCreated(node);
        }
    }
127820
private void locateNode(final String address, final Iterator<String> nodes, final Handler<AsyncResult<String>> doneHandler) {
    if (nodes.hasNext()) {
      final String node = nodes.next();
      vertx.eventBus().sendWithTimeout(node, new JsonObject().putString("action", "ping"), 1000, new Handler<AsyncResult<Message<JsonObject>>>() {
        @Override
        public void handle(AsyncResult<Message<JsonObject>> result) {
          if (result.failed() || result.result().body().getString("status", "ok").equals("error")) {
            removeNode(address, node);
            locateNode(address, nodes, doneHandler);
          } else {
            new DefaultFutureResult<String>(node).setHandler(doneHandler);
          }
        }
      });
    } else {
      new DefaultFutureResult<String>(new IllegalStateException("No local nodes found")).setHandler(doneHandler);
    }
  }
511688
public void finished(final ProcessorGraphNode processorGraphNode) {
        this.processorLock.lock();
        try {
            this.runningProcessors.remove(processorGraphNode.getProcessor());
            this.executedProcessors.put(processorGraphNode.getProcessor(), null);
        } finally {
            this.processorLock.unlock();
        }
    }
1341859
public function addNodeUid($node_name, $uid)
    {
        ProcessManager::getInstance()->getRpcCall(ClusterProcess::class, true)->th_addUid($node_name, $uid);
    }