Click or drag to resize

QueryMessage Constructor

Initializes a new instance of the QueryMessage class.

Namespace:  MongoDB.Driver.Core.WireProtocol.Messages
Assembly:  MongoDB.Driver.Core (in MongoDB.Driver.Core.dll) Version: 2.8.0+cc573f3e1f48f39162b4b680e921a623e127e8fa
Syntax
public QueryMessage(
	int requestId,
	CollectionNamespace collectionNamespace,
	BsonDocument query,
	BsonDocument fields,
	IElementNameValidator queryValidator,
	int skip,
	int batchSize,
	bool slaveOk,
	bool partialOk,
	bool noCursorTimeout,
	bool oplogReplay,
	bool tailableCursor,
	bool awaitData,
	Func<bool> shouldBeSent = null
)

Parameters

requestId
Type: SystemInt32
The request identifier.
collectionNamespace
Type: MongoDB.DriverCollectionNamespace
The collection namespace.
query
Type: MongoDB.BsonBsonDocument
The query.
fields
Type: MongoDB.BsonBsonDocument
The fields.
queryValidator
Type: MongoDB.Bson.IOIElementNameValidator
The query validator.
skip
Type: SystemInt32
The number of documents to skip.
batchSize
Type: SystemInt32
The size of a batch.
slaveOk
Type: SystemBoolean
if set to true it is OK if the server is not the primary.
partialOk
Type: SystemBoolean
if set to true the server is allowed to return partial results if any shards are unavailable.
noCursorTimeout
Type: SystemBoolean
if set to true the server should not timeout the cursor.
oplogReplay
Type: SystemBoolean
if set to true the OplogReplay bit will be set.
tailableCursor
Type: SystemBoolean
if set to true the query should return a tailable cursor.
awaitData
Type: SystemBoolean
if set to true the server should await data (used with tailable cursors).
shouldBeSent (Optional)
Type: SystemFuncBoolean
A delegate that determines whether this message should be sent.
See Also