Skip to content

Commit

Permalink
Add missing docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
another-rex committed Aug 26, 2024
1 parent 85400f5 commit 2719d3b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions gcp/api/cursor.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,12 @@ def from_page_token(cls, page_token: str | None) -> Self:
return qc

def update_from_iterator(self, it: ndb.QueryIterator) -> None:
"""
Update the current cursor from the value of the ndb.iterator passed in.
Args:
it: the iterator to take the cursor position from.
"""
try:
self._ndb_cursor = typing.cast(ndb.Cursor, it.cursor_after())
self._cursor_state = _QueryCursorState.IN_PROGRESS
Expand Down

0 comments on commit 2719d3b

Please sign in to comment.