Class Mql
Contains methods that can be used to access MongoDB specific functionality in LINQ queries.
public static class Mql
- Inheritance
-
Mql
- Inherited Members
Methods
- Constant<TValue>(TValue, BsonType)
Use this method in a MongoDB LINQ query when you need to specify how a constant should be serialized.
- Constant<TValue>(TValue, IBsonSerializer<TValue>)
Use this method in a MongoDB LINQ query when you need to specify how a constant should be serialized.
- Convert<TFrom, TTo>(TFrom, ConvertOptions<TTo>)
Converts a value from one type to another using the $convert aggregation operator.
- CreateObjectId()
Creates a new unique ObjectId using the $createObjectId aggregation operator.
- DateFromString(string)
Converts a string to a DateTime using the $dateFromString aggregation operator.
- DateFromString(string, string)
Converts a string to a DateTime using the $dateFromString aggregation operator.
- DateFromString(string, string, string)
Converts a string to a DateTime using the $dateFromString aggregation operator.
- DateFromString(string, string, string, DateTime?, DateTime?)
Converts a string to a DateTime using the $dateFromString aggregation operator.
- DeserializeEJson<TInput, TOutput>(TInput, DeserializeEJsonOptions<TOutput>)
Deserializes Extended JSON values back to native BSON types using the $deserializeEJSON aggregation operator.
- Exists<TField>(TField)
Tests whether a field exists.
- Field<TDocument, TField>(TDocument, string, IBsonSerializer<TField>)
Gets the value of a field in a document.
- Hash<TValue>(TValue, MqlHashAlgorithm)
Generates a binary hash for an input expression.
- HexHash<TValue>(TValue, MqlHashAlgorithm)
Generates a hexadecimal hash string for an input expression.
- IsMissing<TField>(TField)
Tests whether a field is missing.
- IsNullOrMissing<TField>(TField)
Tests whether a field is null or missing.
- SerializeEJson<TInput, TOutput>(TInput, SerializeEJsonOptions<TOutput>)
Serializes BSON values to their Extended JSON v2 representation using the $serializeEJSON aggregation operator.
- Sigmoid(double)
Transforms a real-valued input into a value between 0 and 1 using the $sigmoid operator.
- SimilarityCosine<TElement>(IEnumerable<TElement>, IEnumerable<TElement>, bool)
Translated to the "$similarityCosine" operator in MQL to measure the similarity between two vectors.
- SimilarityCosine<TElement>(ReadOnlyMemory<TElement>, ReadOnlyMemory<TElement>, bool)
Translated to the "$similarityCosine" operator in MQL to measure the similarity between two vectors.
- SimilarityDotProduct<TElement>(IEnumerable<TElement>, IEnumerable<TElement>, bool)
Translated to the "$similarityDotProduct" operator in MQL to measure the similarity between two vectors.
- SimilarityDotProduct<TElement>(ReadOnlyMemory<TElement>, ReadOnlyMemory<TElement>, bool)
Translated to the "$similarityDotProduct" operator in MQL to measure the similarity between two vectors.
- SimilarityEuclidean<TElement>(IEnumerable<TElement>, IEnumerable<TElement>, bool)
Translated to the "$similarityEuclidean" operator in MQL to measure the similarity between two vectors.
- SimilarityEuclidean<TElement>(ReadOnlyMemory<TElement>, ReadOnlyMemory<TElement>, bool)
Translated to the "$similarityEuclidean" operator in MQL to measure the similarity between two vectors.
- Subtype<TValue>(TValue)
Returns the subtype of a given binary value.