Method Unset
Unset<TDocument>(UpdateDefinition<TDocument>, FieldDefinition<TDocument>)
Combines an existing update with an unset operator.
public static UpdateDefinition<TDocument> Unset<TDocument>(this UpdateDefinition<TDocument> update, FieldDefinition<TDocument> field)
Parameters
updateUpdateDefinition<TDocument>The update.
fieldFieldDefinition<TDocument>The field.
Returns
- UpdateDefinition<TDocument>
A combined update.
Type Parameters
TDocumentThe type of the document.
Unset<TDocument>(UpdateDefinition<TDocument>, Expression<Func<TDocument, object>>)
Combines an existing update with an unset operator.
public static UpdateDefinition<TDocument> Unset<TDocument>(this UpdateDefinition<TDocument> update, Expression<Func<TDocument, object>> field)
Parameters
updateUpdateDefinition<TDocument>The update.
fieldExpression<Func<TDocument, object>>The field.
Returns
- UpdateDefinition<TDocument>
A combined update.
Type Parameters
TDocumentThe type of the document.