Package com.mongodb

Class MongoCursorNotFoundException

All Implemented Interfaces:
Serializable

public class MongoCursorNotFoundException extends MongoQueryException
Subclass of MongoException representing a cursor-not-found exception.
Since:
2.12
  • Constructor Details

    • MongoCursorNotFoundException

      public MongoCursorNotFoundException(long cursorId, BsonDocument response, ServerAddress serverAddress)
      Construct an instance.
      Parameters:
      cursorId - cursor identifier
      response - the server response document
      serverAddress - the server address
      Since:
      4.8
  • Method Details

    • getCursorId

      public long getCursorId()
      Get the cursor id that wasn't found.
      Returns:
      the ID of the cursor