Class MemberSelectorBuilder
- Namespace
- Bonsai.Expressions
- Assembly
- Bonsai.Core.dll
Represents an expression builder that defines a simple selector on the elements of an observable sequence by mapping specified member values into the output data type.
The MemberSelector
operator is used to quickly extract member fields and properties out of the elements of the source sequence. Multiple members can be specified using a comma-separated list in the Selector property, in which case the output type will be a tuple of all selected member types.
The TypeMapping property can be used to specify which type conversion to use when chaining the selected members into downstream operators.
public class MemberSelectorBuilder : SelectBuilder, IExpressionBuilder, INamedElement
- Inheritance
-
MemberSelectorBuilder
- Implements
- Inherited Members
- Extension Methods
Properties
Selector
Gets or sets a string used to select the input element members that will be projected as output of the sequence.
public string Selector { get; set; }
Property Value
TypeMapping
Gets or sets an optional type mapping specifying the data type which the selected properties will be projected into.
[Externalizable(false)]
public TypeMapping TypeMapping { get; set; }
Property Value
Methods
BuildSelector(Expression)
Returns the expression that maps the specified input parameter to the selector result.
protected override Expression BuildSelector(Expression expression)
Parameters
expression
ExpressionThe input parameter to the selector.
Returns
- Expression
The Expression that maps the input parameter to the selector result.