Class EnumerableExpression
- Namespace
- Microsoft.EntityFrameworkCore.Query
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
An expression that represents an enumerable or group translated from chain over a grouping element.
This type is typically used by database providers (and other extensions). It is generally not used in application code.
public class EnumerableExpression : Expression, IPrintableExpression
- Inheritance
-
EnumerableExpression
- Implements
-
IPrintableExpression
- Inherited Members
Constructors
EnumerableExpression(Expression)
Creates a new instance of the EnumerableExpression class.
public EnumerableExpression(Expression selector)
Parameters
selector
ExpressionThe underlying sql expression being enumerated.
Properties
IsDistinct
The value indicating if distinct operator is applied on the enumerable or not.
public virtual bool IsDistinct { get; }
Property Value
NodeType
public override ExpressionType NodeType { get; }
Property Value
Orderings
The list of orderings to be applied to the enumerable.
public virtual IReadOnlyList<OrderingExpression> Orderings { get; }
Property Value
Predicate
The value indicating any predicate applied on the enumerable.
public virtual SqlExpression? Predicate { get; }
Property Value
Selector
The underlying expression being enumerated.
public virtual Expression Selector { get; }
Property Value
Type
public override Type Type { get; }
Property Value
Methods
AppendOrdering(OrderingExpression)
Appends ordering to the existing orderings of the EnumerableExpression.
public virtual EnumerableExpression AppendOrdering(OrderingExpression orderingExpression)
Parameters
orderingExpression
OrderingExpressionAn ordering expression to use for ordering.
Returns
- EnumerableExpression
The new expression with specified component updated.
ApplyDistinct()
Applies DISTINCT operator to the selector of the EnumerableExpression.
public virtual EnumerableExpression ApplyDistinct()
Returns
- EnumerableExpression
The new expression with specified component updated.
ApplyOrdering(OrderingExpression)
Applies ordering to the EnumerableExpression. This overwrites any previous ordering specified.
public virtual EnumerableExpression ApplyOrdering(OrderingExpression orderingExpression)
Parameters
orderingExpression
OrderingExpressionAn ordering expression to use for ordering.
Returns
- EnumerableExpression
The new expression with specified component updated.
ApplyPredicate(SqlExpression)
Applies filter predicate to the EnumerableExpression.
public virtual EnumerableExpression ApplyPredicate(SqlExpression sqlExpression)
Parameters
sqlExpression
SqlExpressionAn expression to use for filtering.
Returns
- EnumerableExpression
The new expression with specified component updated.
ApplySelector(Expression)
Applies new selector to the EnumerableExpression.
public virtual EnumerableExpression ApplySelector(Expression expression)
Parameters
expression
Expression
Returns
- EnumerableExpression
The new expression with specified component updated.
Equals(object?)
public override bool Equals(object? obj)
Parameters
obj
object
Returns
GetHashCode()
public override int GetHashCode()
Returns
Print(ExpressionPrinter)
public virtual void Print(ExpressionPrinter expressionPrinter)
Parameters
expressionPrinter
ExpressionPrinter
VisitChildren(ExpressionVisitor)
protected override Expression VisitChildren(ExpressionVisitor visitor)
Parameters
visitor
ExpressionVisitor