Negates an expression for the current field.

@see Builder::not()
@see http://docs.mongodb.org/manual/reference/operator/not/

@param array|Expr $expression
504410
public function not($expression) : self
    {
        return $this->operator('$not', $expression instanceof Expr ? $expression->getQuery() : $expression);
    }
120192
def Nor(*xs, simplify=True):
    
    xs = [Expression.box(x).node for x in xs]
    y = exprnode.not_(exprnode.or_(*xs))
    if simplify:
        y = y.simplify()
    return _expr(y)
1001652
public function isNull($field)
    {
        return new Expr\ComparisonExpression($field, new Expr\ValueIdentifier(null), Expr\ComparisonExpression::EQ);
    }
890123
public function whereNotNull($expr)
    {
        foreach ($this->queries as $query) {
            $query->whereNotNull($expr);
        }

        return $this;
    }
1280125
@NonNull
    public Expression isNot(@NonNull Expression expression) {
        if (expression == null) {
            throw new IllegalArgumentException("expression cannot be null.");
        }
        return new BinaryExpression(this, expression, BinaryExpression.OpType.IsNot);
    }
900392
public function addExpressionCondition($expression) {
        if(!isset($this->_subscription->subject)){
            $this->_subscription->subject = (object) [];
        }

        if(!isset($this->_subscription->subject->condition)){
            $this->_subscription->subject->condition = (object) [];
        }


        $this->_subscription->subject->condition->expression = $expression;
        return $this;
    }
166252
public function notIn($field, $value) {
        $this->add($field, Expr::NOT_IN, (array) $value);

        return $this;
    }
1300922
public function leaveExpression(Expression $expr)
    {
        if ($expr instanceof OrX || $expr instanceof AndX) {
            $hash = spl_object_hash($expr);

            if ($expr instanceof OrX) {
                $composite = $this->qb->expr()->orX();
                $composite->addMultiple($this->map[$hash]);
            } else {
                $composite = $this->qb->expr()->andX();
                $composite->addMultiple($this->map[$hash]);
            }

            unset($this->hashes[array_search($hash, $this->hashes)]);

            if (!count($this->hashes)) {
                $this->qb->andWhere($composite);
            } else {
                $lastHash = end($this->hashes);

                $this->map[$lastHash][] = $composite;
            }
        }

        return $expr;
    }
455970
function notin($field,$ins)
    {
        if (is_array($ins))
        {
            $ins = implode(',', $ins);
        }
        else
        {
            //去掉两边的分号
            $ins = trim($ins, ',');
        }
        $this->where("`$field` NOT IN ({$ins})");
    }
452153
public function set(string $column, Expr $expression)
    {
        $this->columnSetMap[$column] = $expression;

        return $this;
    }
218955
function not(pred, thisArg) {
    function notPred() {
        return !(notPred.pred.apply(notPred.thisArg, arguments));
    }
    notPred.pred = pred;
    notPred.thisArg = thisArg;
    return notPred;
}
175109
@NonNull
    public static Expression negated(@NonNull Expression expression) {
        if (expression == null) {
            throw new IllegalArgumentException("expression cannot be null.");
        }
        return new CompoundExpression(Arrays.asList(expression), CompoundExpression.OpType.Not);
    }
727994
public function batchDelete($expression)
    {
        // remove
        $result = $this->getMongoCollection()->remove(
            Expression::convertToArray($expression)
        );

        // check result
        if (true !== $result && $result['ok'] != 1) {
            throw new Exception('Error removing documents from collection: ' . $result['err']);
        }

        return $this;
    }
756117
public function elemMatch($expression) : self
    {
        return $this->operator('$elemMatch', $expression instanceof Expr ? $expression->getQuery() : $expression);
    }
1097451
public function exclude($field)
    {
        $fields = (is_array($field) ? $field : func_get_args());

        foreach ($fields as $field) {
            $this->fields[$field] = -1;
        }
    }
1142279
@Override
    public BooleanExpression not() {
        if (not == null) {
            // uses this, because it makes unwrapping easier
            not = Expressions.booleanOperation(Ops.NOT, this);
        }
        return not;
    }
1010665
@NonNull
    public static Expression not(@NonNull Expression expression) {
        if (expression == null) {
            throw new IllegalArgumentException("expression cannot be null.");
        }
        return negated(expression);
    }