Class QueryVisitorWithReflection
Query expression visitor with visit methods for reflection objects.
Inheritance
Inherited Members
Namespace: System.Linq.CompilerServices.Optimizers
Assembly: Nuqleon.Linq.CompilerServices.Optimizers.dll
Syntax
public class QueryVisitorWithReflection : QueryVisitor
Constructors
QueryVisitorWithReflection()
Declaration
public QueryVisitorWithReflection()
Methods
MakeFirst(FirstOperator, Type, MonadMember)
Makes a FirstOperator with the given children.
Declaration
protected virtual QueryOperator MakeFirst(FirstOperator node, Type elementType, MonadMember source)
Parameters
| Type | Name | Description |
|---|---|---|
| FirstOperator | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| MonadMember | source | Source query expression. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Representation of the original query expression. |
MakeFirstPredicate(FirstPredicateOperator, Type, MonadMember, QueryTree)
Makes a FirstPredicateOperator with the given children.
Declaration
protected virtual QueryOperator MakeFirstPredicate(FirstPredicateOperator node, Type elementType, MonadMember source, QueryTree predicate)
Parameters
| Type | Name | Description |
|---|---|---|
| FirstPredicateOperator | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| MonadMember | source | Source query expression. |
| QueryTree | predicate | Predicate query expression. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Representation of the original query expression. |
MakeLambdaAbstraction(LambdaAbstraction, LambdaExpression, ReadOnlyCollection<QueryTree>)
Makes a LambdaAbstraction with the given children.
Declaration
protected virtual QueryTree MakeLambdaAbstraction(LambdaAbstraction node, LambdaExpression body, ReadOnlyCollection<QueryTree> arguments)
Parameters
| Type | Name | Description |
|---|---|---|
| LambdaAbstraction | node | Original query expression. |
| System.Linq.Expressions.LambdaExpression | body | Body expression. |
| System.Collections.ObjectModel.ReadOnlyCollection<QueryTree> | arguments | Argument query expressions. |
Returns
| Type | Description |
|---|---|
| QueryTree | Representation of the original query expression. |
MakeMonadAbstraction(MonadAbstraction, Type, QueryTree)
Makes a MonadAbstraction with the given children.
Declaration
protected virtual MonadMember MakeMonadAbstraction(MonadAbstraction node, Type elementType, QueryTree inner)
Parameters
| Type | Name | Description |
|---|---|---|
| MonadAbstraction | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| QueryTree | inner | Inner query expression. |
Returns
| Type | Description |
|---|---|
| MonadMember | Representation of the original query expression. |
MakeSelect(SelectOperator, Type, Type, MonadMember, QueryTree)
Makes a SelectOperator with the given children.
Declaration
protected virtual QueryOperator MakeSelect(SelectOperator node, Type elementType, Type inputElementType, MonadMember source, QueryTree selector)
Parameters
| Type | Name | Description |
|---|---|---|
| SelectOperator | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| System.Type | inputElementType | Input element type for the resulting operator. |
| MonadMember | source | Source query expression. |
| QueryTree | selector | Selector query expression. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Representation of the original query expression. |
MakeTake(TakeOperator, Type, MonadMember, QueryTree)
Makes a TakeOperator with the given children.
Declaration
protected virtual QueryOperator MakeTake(TakeOperator node, Type elementType, MonadMember source, QueryTree count)
Parameters
| Type | Name | Description |
|---|---|---|
| TakeOperator | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| MonadMember | source | Source query expression. |
| QueryTree | count | Count query expression. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Representation of the original query expression. |
MakeWhere(WhereOperator, Type, MonadMember, QueryTree)
Makes a WhereOperator with the given children.
Declaration
protected virtual QueryOperator MakeWhere(WhereOperator node, Type elementType, MonadMember source, QueryTree predicate)
Parameters
| Type | Name | Description |
|---|---|---|
| WhereOperator | node | Original query expression. |
| System.Type | elementType | Element type for the resulting operator. |
| MonadMember | source | Source query expression. |
| QueryTree | predicate | Predicate query expression. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Representation of the original query expression. |
VisitFirst(FirstOperator)
Visits a FirstOperator node.
Declaration
protected override QueryOperator VisitFirst(FirstOperator op)
Parameters
| Type | Name | Description |
|---|---|---|
| FirstOperator | op | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Result of visiting the node. |
Overrides
VisitFirstPredicate(FirstPredicateOperator)
Visits a FirstPredicateOperator node.
Declaration
protected override QueryOperator VisitFirstPredicate(FirstPredicateOperator op)
Parameters
| Type | Name | Description |
|---|---|---|
| FirstPredicateOperator | op | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Result of visiting the node. |
Overrides
VisitLambdaAbstraction(LambdaAbstraction)
Visits a LambdaAbstraction node.
Declaration
protected override QueryTree VisitLambdaAbstraction(LambdaAbstraction node)
Parameters
| Type | Name | Description |
|---|---|---|
| LambdaAbstraction | node | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryTree | Result of visiting the node. |
Overrides
VisitLambdaAbstractionBody(LambdaExpression)
Visits an expression which is the body of a lambda abstraction.
Declaration
protected virtual LambdaExpression VisitLambdaAbstractionBody(LambdaExpression body)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Linq.Expressions.LambdaExpression | body | The expression to visit. |
Returns
| Type | Description |
|---|---|
| System.Linq.Expressions.LambdaExpression | Result of visiting the expression. |
VisitMonadAbstraction(MonadAbstraction)
Visits a MonadAbstraction node.
Declaration
protected override MonadMember VisitMonadAbstraction(MonadAbstraction node)
Parameters
| Type | Name | Description |
|---|---|---|
| MonadAbstraction | node | Node to visit. |
Returns
| Type | Description |
|---|---|
| MonadMember | Result of visiting the node. |
Overrides
VisitSelect(SelectOperator)
Visits a SelectOperator node.
Declaration
protected override QueryOperator VisitSelect(SelectOperator op)
Parameters
| Type | Name | Description |
|---|---|---|
| SelectOperator | op | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Result of visiting the node. |
Overrides
VisitTake(TakeOperator)
Visits a TakeOperator node.
Declaration
protected override QueryOperator VisitTake(TakeOperator op)
Parameters
| Type | Name | Description |
|---|---|---|
| TakeOperator | op | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Result of visiting the node. |
Overrides
VisitType(Type)
Visits a type.
Declaration
protected virtual Type VisitType(Type type)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Type | type | Type to visit. |
Returns
| Type | Description |
|---|---|
| System.Type | Result of the visit. |
VisitWhere(WhereOperator)
Visits a WhereOperator node.
Declaration
protected override QueryOperator VisitWhere(WhereOperator op)
Parameters
| Type | Name | Description |
|---|---|---|
| WhereOperator | op | Node to visit. |
Returns
| Type | Description |
|---|---|
| QueryOperator | Result of visiting the node. |