MCPcopy Create free account
hub / github.com/mongodb/mongo-python-driver / _check_okay_to_chain

Method _check_okay_to_chain

pymongo/synchronous/cursor.py:357–360  ·  view source on GitHub ↗

Check if it is okay to chain more options onto this cursor.

(self)

Source from the content-addressed store, hash-verified

355 return self._spec
356
357 def _check_okay_to_chain(self) -> None:
358 """Check if it is okay to chain more options onto this cursor."""
359 if self._retrieved or self._id is not None:
360 raise InvalidOperation("cannot set options after executing query")
361
362 def add_option(self, mask: int) -> Cursor[_DocumentType]:
363 """Set arbitrary query flags using a bitmask.

Callers 15

add_optionMethod · 0.95
remove_optionMethod · 0.95
allow_disk_useMethod · 0.95
limitMethod · 0.95
batch_sizeMethod · 0.95
skipMethod · 0.95
max_time_msMethod · 0.95
max_await_time_msMethod · 0.95
__getitem__Method · 0.95
max_scanMethod · 0.95
maxMethod · 0.95
minMethod · 0.95

Calls 1

InvalidOperationClass · 0.90

Tested by

no test coverage detected