Advance the cursor.
(self)
| 1135 | return self |
| 1136 | |
| 1137 | async def next(self) -> _DocumentType: |
| 1138 | """Advance the cursor.""" |
| 1139 | if not self._exhaust_checked: |
| 1140 | self._exhaust_checked = True |
| 1141 | await self._supports_exhaust() |
| 1142 | if self._empty: |
| 1143 | raise StopAsyncIteration |
| 1144 | if len(self._data) or await self._refresh(): |
| 1145 | return self._data.popleft() |
| 1146 | else: |
| 1147 | raise StopAsyncIteration |
| 1148 | |
| 1149 | async def _next_batch(self, result: list, total: Optional[int] = None) -> bool: # type: ignore[type-arg] |
| 1150 | """Get all or some documents from the cursor.""" |
no test coverage detected