def explain(self):
        """Returns an explain plan record for this cursor.

        .. note:: Starting with MongoDB 3.2 :meth:`explain` uses
          the default verbosity mode of the `explain command
          <https://docs.mongodb.com/manual/reference/command/explain/>`_,
          ``allPlansExecution``. To use a different verbosity use
          :meth:`~pymongo.database.Database.command` to run the explain
          command directly.

        .. mongodoc:: explain
        """
        c = self.clone()
        c.__explain = True

        # always use a hard limit for explains
        if c.__limit:
            c.__limit = -abs(c.__limit)
        return next(c)
Returns an explain plan record for this cursor.

        .. note:: Starting with MongoDB 3.2 :meth:`explain` uses
          the default verbosity mode of the `explain command
          <https://docs.mongodb.com/manual/reference/command/explain/>`_,
          ``allPlansExecution``. To use a different verbosity use
          :meth:`~pymongo.database.Database.command` to run the explain
          command directly.

        .. mongodoc:: explain
        
stackoverflow/venv/lib/python3.6/site-packages/pymongo/cursor.py