FilterDefinitionBuilderTDocumentElemMatchTItem Method (ExpressionFuncTDocument, IEnumerableTItem, FilterDefinitionTItem) |
Creates an element match filter for an array field.
Namespace:
MongoDB.Driver
Assembly:
MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.11.0+cb27a82ea70620ad1acad8058809be8302ae4f2a
Syntax public FilterDefinition<TDocument> ElemMatch<TItem>(
Expression<Func<TDocument, IEnumerable<TItem>>> field,
FilterDefinition<TItem> filter
)
Public Function ElemMatch(Of TItem) (
field As Expression(Of Func(Of TDocument, IEnumerable(Of TItem))),
filter As FilterDefinition(Of TItem)
) As FilterDefinition(Of TDocument)
member ElemMatch :
field : Expression<Func<'TDocument, IEnumerable<'TItem>>> *
filter : FilterDefinition<'TItem> -> FilterDefinition<'TDocument>
Parameters
- field
- Type: System.Linq.ExpressionsExpressionFuncTDocument, IEnumerableTItem
The field. - filter
- Type: MongoDB.DriverFilterDefinitionTItem
The filter.
Type Parameters
- TItem
- The type of the item.
Return Value
Type:
FilterDefinitionTDocumentAn element match filter.
See Also