Table of Contents

Class ProjectionDefinitionBuilder<TSource>

Namespace
MongoDB.Driver
Assembly
MongoDB.Driver.dll

A builder for a projection.

public sealed class ProjectionDefinitionBuilder<TSource>

Type Parameters

TSource

The type of the source.

Inheritance
ProjectionDefinitionBuilder<TSource>
Inherited Members

Methods

As<TProjection>(IBsonSerializer<TProjection>)

Creates a client side projection that is implemented solely by using a different serializer.

Combine(params ProjectionDefinition<TSource>[])

Combines the specified projections.

Combine(IEnumerable<ProjectionDefinition<TSource>>)

Combines the specified projections.

ElemMatch<TItem>(FieldDefinition<TSource>, FilterDefinition<TItem>)

Creates a projection that filters the contents of an array.

ElemMatch<TItem>(Expression<Func<TSource, IEnumerable<TItem>>>, FilterDefinition<TItem>)

Creates a projection that filters the contents of an array.

ElemMatch<TItem>(Expression<Func<TSource, IEnumerable<TItem>>>, Expression<Func<TItem, bool>>)

Creates a projection that filters the contents of an array.

Exclude(FieldDefinition<TSource>)

Creates a projection that excludes a field.

Exclude(Expression<Func<TSource, object>>)

Creates a projection that excludes a field.

Expression<TProjection>(Expression<Func<TSource, TProjection>>)

Creates a projection based on the expression.

Include(FieldDefinition<TSource>)

Creates a projection that includes a field.

Include(Expression<Func<TSource, object>>)

Creates a projection that includes a field.

Meta(string, string)

Creates a meta projection.

MetaSearchHighlights(string)

Creates a search highlights projection.

MetaSearchScore(string)

Creates a search score projection.

MetaSearchScoreDetails(string)

Creates a search score details projection.

MetaTextScore(string)

Creates a text score projection.

SearchMeta(FieldDefinition<TSource>)

Creates a search metadata projection.

SearchMeta(Expression<Func<TSource, object>>)

Creates a search metadata projection.

Slice(FieldDefinition<TSource>, int)

Creates an array slice projection.

Slice(FieldDefinition<TSource>, int, int)

Creates an array slice projection.

Slice(Expression<Func<TSource, object>>, int)

Creates an array slice projection.

Slice(Expression<Func<TSource, object>>, int, int)

Creates an array slice projection.