Table of Contents

Method CompareTo

Namespace
MongoDB.Bson
Assembly
MongoDB.Bson.dll

CompareTo(BsonDocument)

Compares this document to another document.

public virtual int CompareTo(BsonDocument rhs)

Parameters

rhs BsonDocument

The other document.

Returns

int

A 32-bit signed integer that indicates whether this document is less than, equal to, or greater than the other.

CompareTo(BsonValue)

Compares the BsonDocument to another BsonValue.

public override int CompareTo(BsonValue other)

Parameters

other BsonValue

The other BsonValue.

Returns

int

A 32-bit signed integer that indicates whether this BsonDocument is less than, equal to, or greater than the other BsonValue.