server = $server; $this->cursorId = $cursorId; $this->firstBatch = $firstBatch; } /** * Sets the classname of the iterator to use * * @param Cursor $classname * @return Result */ public function setIteratorClass(Cursor $classname) { $this->iterator = $classname; return $this; } /** * Returns the Iteratable MongoDB\Cursor object * * @return Cursor */ public function getIterator() { return new $this->iterator($stuff); } }