Click or drag to resize

MongoCursorTDocument Constructor (MongoCollection, IMongoQuery, ReadPreference, IBsonSerializer)

Note: This API is now obsolete.

Creates a new MongoCursor. It is very unlikely that you will call this constructor. Instead, see all the Find methods in MongoCollection.

Namespace:  MongoDB.Driver
Assembly:  MongoDB.Driver.Legacy (in MongoDB.Driver.Legacy.dll) Version: 2.10.0+569905ff5e778c38ea19d9d0392496a83e1704ed
Syntax
[ObsoleteAttribute("Use a method that returns a cursor instead.")]
public MongoCursor(
	MongoCollection collection,
	IMongoQuery query,
	ReadPreference readPreference,
	IBsonSerializer serializer
)

Parameters

collection
Type: MongoDB.DriverMongoCollection
The collection.
query
Type: MongoDB.DriverIMongoQuery
The query.
readPreference
Type: MongoDB.DriverReadPreference
The read preference.
serializer
Type: MongoDB.Bson.SerializationIBsonSerializer
The serializer.
See Also