Doctrine\MongoDB\Query\Builder::addToSet PHP 메소드

addToSet() 공개 메소드

If the field does not exist, it will be set to an array containing the unique value(s) in the argument. If the field is not an array, the query will yield an error. Multiple values may be specified by provided an Expr object and using {@link Expr::each()}.
또한 보기: Expr::addToSet()
또한 보기: http://docs.mongodb.org/manual/reference/operator/addToSet/
또한 보기: http://docs.mongodb.org/manual/reference/operator/each/
public addToSet ( mixed | Expr $valueOrExpression )
$valueOrExpression mixed | Expr
    public function addToSet($valueOrExpression)
    {
        $this->expr->addToSet($valueOrExpression);
        return $this;
    }