cursor.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:aiomongo 作者: ZeoAlliance 项目源码 文件源码
def skip(self, skip: int) -> 'Cursor':
        """Skips the first `skip` results of this cursor.

        Raises :exc:`TypeError` if `skip` is not an integer. Raises
        :exc:`ValueError` if `skip` is less than ``0``. Raises
        :exc:`~pymongo.errors.InvalidOperation` if this :class:`Cursor` has
        already been used. The last `skip` applied to this cursor takes
        precedence.

        :Parameters:
          - `skip`: the number of results to skip
        """
        if not isinstance(skip, int):
            raise TypeError('skip must be an integer')
        if skip < 0:
            raise ValueError('skip must be >= 0')
        self.__check_okay_to_chain()

        self.__skip = skip
        return self
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号