Negates another ElementSelector.
502054
public static ElementSelector not(final ElementSelector es) {
        if (es == null) {
            throw new IllegalArgumentException("es must not be null");
        }
        return new ElementSelector() {
            @Override
            public boolean canBeCompared(Element controlElement,
                                         Element testElement) {
                return !es.canBeCompared(controlElement, testElement);
            }
        };
    }
285591
def remove(self, element):
        """"""
        try:
            index = self.index(element)
        except ValueError:
            raise ValueError("list.remove(x): x not in list")
        else:
            self._notify_remove_at(index)
            super(ObservableList, self).pop(index)
22992
def isolate_element(self, x):
        """"""
        members = list(self.members(x))
        self.delete_set(x)
        self.union(*(v for v in members if v != x))
909680
private void negateRange(final ShortBuffer buffer, final int startIndex, final int lastIndex,
      final int startRange, final int lastRange) {
    // compute the negation into buffer

    int outPos = 0;
    int inPos = startIndex; // value here always >= valInRange,
    // until it is exhausted
    // n.b., we can start initially exhausted.

    int valInRange = startRange;
    for (; valInRange < lastRange && inPos <= lastIndex; ++valInRange) {
      if ((short) valInRange != content.get(inPos)) {
        buffer.put(outPos++, (short) valInRange);
      } else {
        ++inPos;
      }
    }

    // if there are extra items (greater than the biggest
    // pre-existing one in range), buffer them
    for (; valInRange < lastRange; ++valInRange) {
      buffer.put(outPos++, (short) valInRange);
    }

    if (outPos != buffer.limit()) {
      throw new RuntimeException(
          "negateRange: outPos " + outPos + " whereas buffer.length=" + buffer.limit());
    }
    assert outPos == buffer.limit();
    // copy back from buffer...caller must ensure there is room
    int i = startIndex;
    int len = buffer.limit();
    for (int k = 0; k < len; ++k) {
      final short item = buffer.get(k);
      content.put(i++, item);
    }
  }
868505
public Vector2i negate(Vector2i dest) {
        dest.x = -x;
        dest.y = -y;
        return dest;
    }
650723
public static void skipElement(final XMLStreamReader reader) throws XMLStreamException, IOException {
        if (reader.getEventType() != XMLStreamConstants.START_ELEMENT) {
            return;
        }
        final String namespace = reader.getNamespaceURI();
        final String name = reader.getLocalName();
        for (;;) {
            switch (reader.nextTag()) {
            case XMLStreamConstants.START_ELEMENT:
                // call ourselves recursively if we encounter START_ELEMENT
                skipElement(reader);
                break;
            case XMLStreamConstants.END_ELEMENT:
            case XMLStreamConstants.END_DOCUMENT:
                // discard events until we encounter matching END_ELEMENT
                reader.require(XMLStreamConstants.END_ELEMENT, namespace, name);
                reader.next();
                return;
            }
        }
    }
948116
static int[] negate(int[] x, int Max) {
    int[] ans = new int[Max - x.length];
    int i = 0;
    int c = 0;
    for (int j = 0; j < x.length; ++j) {
      int v = x[j];
      for (; i < v; ++i)
        ans[c++] = i;
      ++i;
    }
    while (c < ans.length)
      ans[c++] = i++;
    return ans;
  }
426181
protected function Neg()
	{
	    throw XPath2Exception::withErrorCodeAndParams( "XPTY0004", Resources::UnaryOperatorNotDefined,
			array(
				"fn:unary-minus",
				SequenceType::WithTypeCodeAndCardinality( SequenceType::GetXmlTypeCodeFromObject( $this->_value ), XmlTypeCardinality::One )
			)
		);
	}
950088
public static boolean areElementEquals(Element element1, Element element2) {
		for (Mask mask1 : element1.getMask()) {
			if (!areBooleanEquals(element1.isNegated(), element2.isNegated())) {
				// Negated.
				return false;
			}
			for (Mask mask2 : element2.getMask()) {
				if (!areStringEquals(mask1.getLexemeMask(), mask2.getLexemeMask())) {
					// LexemeMask.
					return false;
				} else if (!areStringEquals(mask1.getPrimitiveMask(), mask2.getPrimitiveMask())) {
					// PrimitiveMask.
					return false;
				} else if (!areTagMaskEquals(mask1.getTagMask(), mask2.getTagMask())) {
					// TagMask.
					return false;
				}
			}
		}
		return true;
	}
125714
function _not(val) {
    if (arguments.length === 1) {
      this._notFlag = val;
      return this;
    }
    var ret = this._notFlag;
    this._notFlag = false;
    return ret;
  }
680094
def negation
      if @entry.at_xpath('./cda:act[@actionNegationInd="true"]')
        is_negation_rationale = (comparison.restrictions.map {|restriction| restriction.type }).include? 'RSON' if comparison
        if is_negation_rationale
          false
        else
          true
        end
      else
        false
      end
    end
1324926
def skip(self):
        
        for pos, element in self.element_iter:
            tag, class_attr = _tag_and_class_attr(element)
            if tag == "div" and "thread" in class_attr and pos == "end":
                break
847384
public void removeRelationshipsNotConnectedToElement(Element element) {
        if (element != null) {
            getRelationships().stream()
                    .map(RelationshipView::getRelationship)
                    .filter(r -> !r.getSource().equals(element) && !r.getDestination().equals(element))
                    .forEach(this::remove);
        }
    }
788283
public static <T1, T2> BiPredicate<T1, T2> not(BiPredicate<T1, T2> predicate) {
        dbc.precondition(predicate != null, "cannot negate a null predicate");
        return predicate.negate();
    }
148246
public synchronized void removeElement(T element) {
    checkArgument(
        element.getNext() != null || element.getPrev() != null || element == head,
        "Element not in the list.");
    size--;
    T prev = element.getPrev();
    T next = element.getNext();
    if (prev == null) {
      // This is the first element
      head = next;
      if (head != null) {
        // If more than one element in the list.
        head.setPrev(null);
        element.setNext(null);
      }
    } else if (next == null) {
      // This is the last element, and there is at least another element because
      // element.getPrev() != null.
      prev.setNext(null);
      element.setPrev(null);
    } else {
      prev.setNext(element.getNext());
      next.setPrev(element.getPrev());
      element.setNext(null);
      element.setPrev(null);
    }
  }
56455
function negate(out, a) {
    out[0] = -a[0]
    out[1] = -a[1]
    out[2] = -a[2]
    return out
}
959392
def _neg(node):
    """"""
    if node is BDDNODEZERO:
        return BDDNODEONE
    elif node is BDDNODEONE:
        return BDDNODEZERO
    else:
        return _bddnode(node.root, _neg(node.lo), _neg(node.hi))