Doctrine\MongoDB\Query\Expr::popFirst PHP Метод

popFirst() публичный Метод

Remove the first element from the current array field.
См. также: Builder::popFirst()
См. также: http://docs.mongodb.org/manual/reference/operator/pop/
public popFirst ( )
    public function popFirst()
    {
        $this->requiresCurrentField();
        $this->newObj['$pop'][$this->currentField] = 1;
        return $this;
    }

Usage Example

Пример #1
0
 /**
  * Remove the first element from the current array field.
  *
  * @see Expr::popFirst()
  * @see http://docs.mongodb.org/manual/reference/operator/pop/
  * @return self
  */
 public function popFirst()
 {
     $this->expr->popFirst();
     return $this;
 }