Class InclusiveProjectionBuilder<T>
A builder for inclusive projections.
public class InclusiveProjectionBuilder<T> : ProjectionBuilderBase<T, InclusiveProjectionBuilder<T>>, IProjectionBuilder
Type Parameters
TThe type of the document.
- Inheritance
-
InclusiveProjectionBuilder<T>
- Implements
- Inherited Members
Methods
Clone()
Creates a copy of this projection builder.
public override IProjectionBuilder Clone()
Returns
ExcludeSpecial(string)
Specify a special field to exclude from the projection.
public InclusiveProjectionBuilder<T> ExcludeSpecial(string fieldName)
Parameters
fieldNamestringThe name of the field to exclude.
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
ExcludeSpecial<TField>(Expression<Func<T, TField>>)
Specify a special field to exclude from the projection.
public InclusiveProjectionBuilder<T> ExcludeSpecial<TField>(Expression<Func<T, TField>> fieldExpression)
Parameters
fieldExpressionExpression<Func<T, TField>>
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
Type Parameters
TField
Include(string)
Specify a field to include in the projection.
public InclusiveProjectionBuilder<T> Include(string fieldName)
Parameters
fieldNamestringThe name of the field to include.
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
Include<TField>(Expression<Func<T, TField>>)
Specify a field to include in the projection.
public InclusiveProjectionBuilder<T> Include<TField>(Expression<Func<T, TField>> fieldExpression)
Parameters
fieldExpressionExpression<Func<T, TField>>The field to include in the projection.
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
Type Parameters
TFieldThe type of the field to include.
Slice(string, int, int)
Specify a field to include in the projection.
public InclusiveProjectionBuilder<T> Slice(string fieldName, int start, int length = 0)
Parameters
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
Slice<TField>(Expression<Func<T, TField>>, int, int)
Specify a field to include in the projection.
public InclusiveProjectionBuilder<T> Slice<TField>(Expression<Func<T, TField>> fieldExpression, int start, int length = 0)
Parameters
fieldExpressionExpression<Func<T, TField>>The field to include in the projection.
startintlengthint
Returns
- InclusiveProjectionBuilder<T>
The projection builder.
Type Parameters
TFieldThe type of the field to include.