Creates a MongoDBRef.

Namespace: MongoDB.Driver
Assembly: MongoDB.Driver (in MongoDB.Driver.dll) Version: 1.2.0.4274

Syntax

C#
public MongoDBRef(
	string collectionName,
	BsonValue id
)
Visual Basic
Public Sub New ( _
	collectionName As String, _
	id As BsonValue _
)
Visual C++
public:
MongoDBRef(
	String^ collectionName, 
	BsonValue^ id
)

Parameters

collectionName
Type: System..::..String
The name of the collection that contains the document.
id
Type: MongoDB.Bson..::..BsonValue
The Id of the document.

See Also