Skip to content

Commit d2efbdc

Browse files
committed
Deprecate DBCursor#hint(String)
JAVA-3028
1 parent 014b040 commit d2efbdc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,9 @@ public DBCursor hint(final DBObject indexKeys) {
440440
* @param indexName the name of an index
441441
* @return same DBCursor for chaining operations
442442
* @mongodb.driver.manual reference/operator/meta/hint/ $hint
443+
* @deprecated Prefer {@link #hint(DBObject)}
443444
*/
445+
@Deprecated
444446
public DBCursor hint(final String indexName) {
445447
findOptions.getModifiers().put("$hint", indexName);
446448
return this;

0 commit comments

Comments
 (0)