Add a VM or a node to the script.

@param el the element to add
@return {@code true} if the was was added
341166
public boolean add(BtrpElement el) {
        switch (el.type()) {
            case VM:
                if (!this.vms.add((VM) el.getElement())) {
                    return false;
                }
                break;
            case NODE:
                if (!this.nodes.add((Node) el.getElement())) {
                    return false;
                }
                break;
            default:
                return false;
        }
        return true;

    }
1057439
public boolean addElement(P element) {
		boolean changed = false;
		if (element != null) {
			final GridCellElement<P> gridElement = new GridCellElement<>(element);
			for (final GridCell<P> cell : getGridCellsOn(element.getGeoLocation().toBounds2D(), true)) {
				if (cell.addElement(gridElement)) {
					changed = true;
				}
			}
		}
		if (changed) {
			++this.elementCount;
		}
		return changed;
	}
1234361
public synchronized Node addNode(@NonNull Node node) {
        version++;

        if (buildMode == MeshBuildMode.MESH) {
            // :)
            val candidate = fillQueue.poll();

            // adding node to the candidate
            candidate.addDownstreamNode(node);

            // adding this node for future connections
            for (int e = 0; e < MAX_DOWNSTREAMS; e++)
                fillQueue.add(node);

            sortedNodes.add(node);
            Collections.sort(sortedNodes);
        } else {
            rootNode.addDownstreamNode(node);
        }

        // after all we add this node to the flattened map, for future access
        nodeMap.put(node.getId(), node);

        return node;
    }
54495
function (ele) {
            var node = this[0];
            //(ele string ??)
            if (node.parentNode) {
                node.parentNode.insertBefore(ele, node.nextSibling);
            }
            return this;
        }
251616
public VNode el(String tag, VNodeData data, Object... children) {
    return this.function.create(tag, data, children);
  }
1074388
public synchronized void addElement(@NonNull T element) {
        hashCached = false;
        this.elementsMap.put(element.getLabel(), element);
        this.elements.add(element);
    }
134800
@Override
  @NullSafe
  public synchronized void add(T element) {

    Optional.ofNullable(element)
      .ifPresent(it -> {

        int hashCode = it.hashCode();
        int index = (hashCode % getScale());

        BloomFilter<T> bloomFilter = resolveBloomFilter(index);

        bloomFilter.add(it);
      });
  }
22525
private boolean insert(T element) {
        if (!entries.containsKey(element)) {
            head = createEntry(element, head);
            entries.put(element, head);
            return true;
        }
        return false;
    }
1313906
@Override
    public boolean addToken(T element) {
        boolean ret = false;
        T oldElement = vocabulary.putIfAbsent(element.getStorageId(), element);
        if (oldElement == null) {
            //putIfAbsent added our element
            if (element.getLabel() != null) {
                extendedVocabulary.put(element.getLabel(), element);
            }
            oldElement = element;
            ret = true;
        } else {
            oldElement.incrementSequencesCount(element.getSequencesCount());
            oldElement.increaseElementFrequency((int) element.getElementFrequency());
        }
        totalWordCount.addAndGet((long) oldElement.getElementFrequency());
        return ret;
    }
178160
public ElemTemplateElement appendChild(ElemTemplateElement newChild)
  {

    int type = ((ElemTemplateElement) newChild).getXSLToken();

    switch (type)
    {
    case Constants.ELEMNAME_TEXTLITERALRESULT :
      break;
    default :
      error(XSLTErrorResources.ER_CANNOT_ADD,
            new Object[]{ newChild.getNodeName(),
                          this.getNodeName() });  //"Can not add " +((ElemTemplateElement)newChild).m_elemName +

    //" to " + this.m_elemName);
    }

    return super.appendChild(newChild);
  }
324866
def addElement(self, *ele):
        
        for el in list(Models.flatten(ele)):
            e = copy.deepcopy(el)
            self._lattice_eleobjlist.append(e)
            self._lattice_elenamelist.append(e.name)
            self._lattice_elecnt += 1
        # update lattice, i.e. beamline element

        # self._lattice.setConf(Models.makeLatticeString(self._lattice_elenamelist))
        self._lattice.setConf(Models.makeLatticeDict(self._lattice_elenamelist))

        # positioning elements
        self.initPos()

        return self._lattice_elecnt
1075966
def addSibling(self, elem):
        
        if elem is None: elem__o = None
        else: elem__o = elem._o
        ret = libxml2mod.xmlAddSibling(self._o, elem__o)
        if ret is None:raise treeError('xmlAddSibling() failed')
        __tmp = xmlNode(_obj=ret)
        return __tmp
1255164
private void addToCreateElements(String elementName) {
        HashMap<String, String> elementAttributes = new HashMap<>();

        elementAttributes.put(XsdAbstractElement.NAME_TAG, elementName);

        if (!createdElements.containsKey(getCleanName(elementName))){
            createdElements.put(getCleanName(elementName), new XsdElement(null, elementAttributes));
        }
    }
265746
@Override
    public void add(int index, T elem) {
        /* Confirm the validity of the index. */
        if (index < 0 || index >= size())
            throw new IndexOutOfBoundsException("Index " + index + ", size " + size());

        /* Add a dummy element to ensure that everything resizes correctly.
         * There's no reason to repeat the logic.
         */
        add(null);

        /* Next, we need to shuffle down every element that appears after
         * the inserted element.  We'll do this using our own public interface.
         */
        for (int i = size(); i > index; ++i)
            set(i, get(i - 1));

        /* Finally, write the element. */
        set(index, elem);
    }
1215532
public synchronized void addElement(T element) {
    checkArgument(
        element.getNext() == null && element.getPrev() == null && element != head,
        "Element already in a list.");
    size++;
    if (head == null) {
      head = element;
    } else {
      head.setPrev(element);
      element.setNext(head);
      head = element;
    }
  }
523012
public void add(E element) {
       long hash;
       String valString = element.toString();
       for (int x = 0; x < k; x++) {
           hash = createHash(valString + Integer.toString(x));
           hash = hash % (long)bitSetSize;
           bitset.set(Math.abs((int)hash), true);
       }
       numberOfAddedElements ++;
    }
326529
@Override
	public void add(long value, T element) {
		if (root == null) {
			root = new Node<T>(value, element, false);
			first = last = root;
			return;
		}
		root = add(value, element, root);
		root.red = false;
	}