Add the passed OOB nodes to the head.

@param aAllOOBNodes
The out-of-band node list. Usually retrieved from
{@link #getAllOutOfBandNodesWithMergedInlineNodes()}. May not be
<code>null</code>.
189115
public void addAllOutOfBandNodesToHead (@Nonnull final List <IHCNode> aAllOOBNodes)
  {
    ValueEnforcer.notNull (aAllOOBNodes, "AllOOBNodes");
    // And now add all to head in the correct order
    for (final IHCNode aNode : aAllOOBNodes)
    {
      final IHCNode aUnwrappedNode = HCHelper.getUnwrappedNode (aNode);

      // Node for the body?
      if (HCJSNodeDetector.isDirectJSNode (aUnwrappedNode))
        m_aHead.addJS (aNode);
      else
        if (HCCSSNodeDetector.isDirectCSSNode (aUnwrappedNode))
          m_aHead.addCSS (aNode);
        else
          throw new IllegalStateException ("Found illegal out-of-band head node: " + aNode);
    }
  }
1222503
def _add_nodes(self):
        """"""
        for n, atom in enumerate(self.ast.select('atom')):
            self.add_node(n, atom=atom)
            self._atom_indices[id(atom)] = n
1357178
public void collectFromRoot(Collection<ResourcePathNode<D>> nodes) {

    if (this.parent != null) {
      this.parent.collectFromRoot(nodes);
    }
    nodes.add(this);
  }
268012
public void addLoop(ArrayComprehensionLoop acl) {
        assertNotNull(acl);
        loops.add(acl);
        acl.setParent(this);
    }
1019390
public void addNode(NodeT node) {
        node.setOwner(this);
        nodeTable.put(node.key(), node);
    }
486757
public static AnnotationNode addAnnotationOrGetExisting(ClassNode classNode, Class<? extends Annotation> annotationClass) {
        return addAnnotationOrGetExisting(classNode, annotationClass, Collections.<String, Object>emptyMap());
    }
1068311
public void add(ImprintNode... nodes) throws HashException {
        notNull(nodes, "Nodes");
        for (ImprintNode node : nodes) {
            add(node);
        }
    }
735400
public void addEdge(final Collection<HypergraphNode<T>> nodes) {
    final HypergraphEdge<T> edge = new HypergraphEdge<>(nodes);
    this.nodes.addAll(nodes);
    this.edges.add(edge);
  }
1051859
@Override
    public void add(ImprintNode node) {
        Util.notNull(node, "Node");
        if (node.getLevel() != 0) {
            throw new IllegalArgumentException("ImprintNode with level greater than 0 is not supported by BlindingMaskLinkingHashTreeBuilder");
        }
        ImprintNode newNode = calculateNewNode(node);
        hashTreeBuilder.add(newNode);
        previousBlockHash = new DataHash(newNode.getValue());
    }
494549
private void writeNodes(RowOutputInterface out) throws IOException {

        out.writeSize(storageSize);

        NodeAVL n = nPrimaryNode;

        while (n != null) {
            n.write(out);

            n = n.nNext;
        }

        hasNodesChanged = false;
    }
1094914
public void setNodeSnapshots(java.util.Collection<NodeSnapshot> nodeSnapshots) {
        if (nodeSnapshots == null) {
            this.nodeSnapshots = null;
            return;
        }

        this.nodeSnapshots = new com.amazonaws.internal.SdkInternalList<NodeSnapshot>(nodeSnapshots);
    }
114743
public List<Node> siblingNodes() {
        if (parentNode == null)
            return Collections.emptyList();

        List<Node> nodes = parentNode.ensureChildNodes();
        List<Node> siblings = new ArrayList<>(nodes.size() - 1);
        for (Node node: nodes)
            if (node != this)
                siblings.add(node);
        return siblings;
    }
657478
public synchronized void addAll(T... nodes) {
        for (T node : nodes)
            addInternal(node,defaultReplication);
        refreshTable();
    }

    /**
     * 
     */
    public synchronized void addAll(Collection<? extends T> nodes) {
        for (T node : nodes)
            addInternal(node,defaultReplication);
        refreshTable();
    }

    /**
     * Calls {@link #add(Object,int)} with all the arguments.
     */
    public synchronized void addAll(Map<? extends T,Integer> nodes) {
        for (Map.Entry<? extends T,Integer> node : nodes.entrySet())
            addInternal(node.getKey(),node.getValue());
        refreshTable();
    }

    /**
     * Removes the node entirely. This is the same as {@code add(node,0)}
     */
    public synchronized void remove(T node) {
        add(node, 0);
    }

    /**
     * Adds a new node with the given number of replica.
     */
    public synchronized void add(T node, int replica) {
        addInternal(node, replica);
        refreshTable();
    }

    private synchronized void addInternal(T node, int replica) {
        if (replica==0) {
            items.remove(node);
        } else {
            Point[] points = new Point[replica];
            String seed = hash.hash(node);
            for (int i=0; i<replica; i++)
                points[i] = new Point(md5(seed+':'+i),node);
            items.put(node,points);
        }
    }

    private synchronized void refreshTable() {
        table = new Table();
    }

    /**
     * Compresses a string into an integer with MD5.
     */
    private int md5(String s) {
        try {
            MessageDigest md5 = MessageDigest.getInstance("MD5");
            md5.update(s.getBytes());
            byte[] digest = md5.digest();

            // 16 bytes -> 4 bytes
            for (int i=0; i<4; i++)
                digest[i] ^= digest[i+4]+digest[i+8]+digest[i+12];
            return (b2i(digest[0])<< 24)|(b2i(digest[1])<<16)|(b2i(digest[2])<< 8)|b2i(digest[3]);
        } catch (GeneralSecurityException e) {
            throw new RuntimeException("Could not generate MD5 hash", e);
        }
    }

    /**
     * unsigned byte->int.
     */
    private int b2i(byte b) {
        return ((int)b)&0xFF;
    }

    /**
     * Looks up a consistent hash with the given data point.
     *
     * <p>
     * The whole point of this class is that if the same query point is given,
     * it's likely to return the same result even when other nodes are added/removed,
     * or the # of replicas for the given node is changed.
     *
     * @return
     *      null if the consistent hash is empty. Otherwise always non-null.
     */
    public T lookup(int queryPoint) {
        return table.lookup(queryPoint);
    }

    /**
     * Takes a string, hash it with MD5, then calls {@link #lookup(int)}. 
     */
    public T lookup(String queryPoint) {
        return lookup(md5(queryPoint));
    }

    /**
     * Creates a permutation of all the nodes for the given data point.
     *
     * <p>
     * The returned permutation is consistent, in the sense that small change
     * to the consistent hash (like addition/removal/change of replicas) only
     * creates a small change in the permutation.
     *
     * <p>
     * Nodes with more replicas are more likely to show up early in the list
     */
    public Iterable<T> list(final int queryPoint) {
        return new Iterable<T>() {
            public Iterator<T> iterator() {
                return table.list(queryPoint);
            }
        };
    }

    /**
     * Takes a string, hash it with MD5, then calls {@link #list(int)}.
     */
    public Iterable<T> list(String queryPoint) {
        return list(md5(queryPoint));
    }
}
819802
public void addNode(N node)
    {
        if(!nodes.containsKey(node))
            nodes.put(node, new Pair<HashSet<N>, HashSet<N>>(new HashSet<N>(), new HashSet<N>()));
    }
1136624
public void addNode(RNode newNode) {
        graph.add(newNode);
        graphBitSet.set(graph.size() - 1);
    }
574784
<T extends Node> NodeList<T> add(NodeList<T> list, T obj) {
        if (list == null) {
            list = new NodeList<>();
        }
        list.add(obj);
        return list;
    }
1097119
@Override
	public void addNode(Node n) {
		if (nodeAccess.getCapacity() < getNodeIndex(nodePos) + NODE_SIZE)
			nodeAccess.ensureCapacity(nodeAccess.getCapacity() + INITIAL_NODE_FILE_SIZE);
		nodIdMapping.put(n.getId(), nodePos);
		
		long nodeIndex = getNodeIndex(nodePos);
		
		nodeAccess.setLong( nodeIndex      , n.getId() );
		nodeAccess.setLong( nodeIndex + 8  ,    -1l    );
		nodeAccess.setLong( nodeIndex + 16 ,    -1l    );
		
		nodeAccess.setLong( 0 , ++nodePos );
		
	}