Skip to content

Commit 29edbd4

Browse files
committed
Deprecate DBCursor.explain
JAVA-3243
1 parent 7d0389c commit 29edbd4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

driver-legacy/src/main/com/mongodb/DBCursor.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -517,8 +517,10 @@ public DBCursor snapshot() {
517517
*
518518
* @return a {@code DBObject} containing the explain output for this DBCursor's query
519519
* @throws MongoException if the operation failed
520-
* @mongodb.driver.manual reference/explain Explain Output
520+
* @mongodb.driver.manual reference/command/explain Explain Output
521+
* @deprecated Replace with direct use of the explain command using the runCommand helper method
521522
*/
523+
@Deprecated
522524
public DBObject explain() {
523525
return toDBObject(executor.execute(getQueryOperation(collection.getObjectCodec())
524526
.asExplainableOperation(ExplainVerbosity.QUERY_PLANNER),

0 commit comments

Comments
 (0)