mirror of
https://github.com/mongodb/mongo.git
synced 2024-11-30 09:06:21 +01:00
hint
This commit is contained in:
parent
33c50a60a3
commit
6a70dab62b
@ -121,6 +121,13 @@ DBQuery.prototype.sort = function( sortBy ){
|
||||
return this;
|
||||
}
|
||||
|
||||
DBQuery.prototype.hint = function( hint ){
|
||||
this._ensureSpecial();
|
||||
this._query["$hint"] = hint;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
DBQuery.prototype.forEach = function( func ){
|
||||
while ( this.hasNext() )
|
||||
func( this.next() );
|
||||
|
Loading…
Reference in New Issue
Block a user