Doctrine\MongoDB\Query\Builder::returnNew PHP Method

returnNew() public method

Set the "new" option for a findAndUpdate command.
public returnNew ( boolean $bool = true )
$bool boolean
    public function returnNew($bool = true)
    {
        $this->query['new'] = (bool) $bool;
        return $this;
    }

Usage Example

Beispiel #1
0
 /**
  * @param bool $bool
  * @return self
  */
 public function returnNew($bool = true)
 {
     $this->refresh(true);
     parent::returnNew($bool);
     return $this;
 }