C# Class IQ.Data.OrderByRewriter

Moves order-bys to the outermost select if possible
Inheritance: DbExpressionVisitor
ファイルを表示 Open project: maravillas/linq-to-delicious

Public Methods

Method Description
Rewrite ( Expression expression ) : Expression

Protected Methods

Method Description
PrependOrderings ( IList newOrderings ) : void

Add a sequence of order expressions to an accumulated list, prepending so as to give precedence to the new expressions over any previous expressions

RebindOrderings ( IEnumerable orderings, TableAlias alias, HashSet existingAliases, IEnumerable existingColumns ) : BindResult

Rebind order expressions to reference a new alias and add to column declarations if necessary

VisitJoin ( JoinExpression join ) : Expression
VisitSelect ( SelectExpression select ) : Expression
VisitSubquery ( SubqueryExpression subquery ) : Expression

Private Methods

Method Description
OrderByRewriter ( ) : System

Method Details

PrependOrderings() protected method

Add a sequence of order expressions to an accumulated list, prepending so as to give precedence to the new expressions over any previous expressions
protected PrependOrderings ( IList newOrderings ) : void
newOrderings IList
return void

RebindOrderings() protected method

Rebind order expressions to reference a new alias and add to column declarations if necessary
protected RebindOrderings ( IEnumerable orderings, TableAlias alias, HashSet existingAliases, IEnumerable existingColumns ) : BindResult
orderings IEnumerable
alias TableAlias
existingAliases HashSet
existingColumns IEnumerable
return BindResult

Rewrite() public static method

public static Rewrite ( Expression expression ) : Expression
expression System.Linq.Expressions.Expression
return System.Linq.Expressions.Expression

VisitJoin() protected method

protected VisitJoin ( JoinExpression join ) : Expression
join JoinExpression
return System.Linq.Expressions.Expression

VisitSelect() protected method

protected VisitSelect ( SelectExpression select ) : Expression
select SelectExpression
return System.Linq.Expressions.Expression

VisitSubquery() protected method

protected VisitSubquery ( SubqueryExpression subquery ) : Expression
subquery SubqueryExpression
return System.Linq.Expressions.Expression