Click or drag to resize

CommonExpression Class

The class which is placed between Expression and our own expression classes. This way we can introduce a Handle routine to simulare multiple-dynamic dispatch ala the visitor pattern, as the normal Expression object doesn't offer that feature and we're otherwise stuck with large bug switch / case statements. (still a switch/case is needed for .NET's Expression classes)
Inheritance Hierarchy
System.Object
  System.Linq.Expressions.Expression
    SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.CommonExpression
      More...

Namespace:  SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses
Assembly:  SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: 5.9.0.0 (5.9.0)
Syntax
public abstract class CommonExpression : Expression

The CommonExpression type exposes the following members.

Constructors
  NameDescription
Protected methodCommonExpression
Initializes a new instance of the CommonExpression class.
Top
Properties
  NameDescription
Public propertyCanReduce
Indicates that the node can be reduced to a simpler node. If this returns true, Reduce() can be called to produce the reduced form.
(Inherited from Expression.)
Public propertyNodeType
Gets the node type of this Expression.
(Overrides Expression.NodeType.)
Public propertyType
Gets the static type of the expression that this Expression represents.
(Overrides Expression.Type.)
Top
Methods
  NameDescription
Protected methodAccept
Dispatches to the specific visit method for this node type. For example, MethodCallExpression calls the VisitMethodCall(MethodCallExpression).
(Inherited from Expression.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodHandle
Handles this instance using the specified handler.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodReduce
Reduces this node to a simpler expression. If CanReduce returns true, this should return a valid expression. This method can return another node which itself must be reduced.
(Inherited from Expression.)
Public methodReduceAndCheck
Reduces this node to a simpler expression. If CanReduce returns true, this should return a valid expression. This method can return another node which itself must be reduced.
(Inherited from Expression.)
Public methodReduceExtensions
Reduces the expression to a known node type (that is not an Extension node) or just returns the expression if it is already a known type.
(Inherited from Expression.)
Public methodToString
Returns a textual representation of the Expression.
(Inherited from Expression.)
Protected methodVisitChildren
Reduces the node and then calls the visitor delegate on the reduced expression. The method throws an exception if the node is not reducible.
(Inherited from Expression.)
Top
See Also
Inheritance Hierarchy
System.Object
  System.Linq.Expressions.Expression
    SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.CommonExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.AllAnyExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.ContainsExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.DbFunctionCallExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.EntityFieldExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.ExcludeIncludeFieldsExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.FilterExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.GroupByKeyReferenceExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.InClauseExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.InMemoryEvalCandidateExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.LikeExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.LLBLGenProExpressionExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.PathEdgeExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.PrefetchPathExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.ProjectionExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.ProjectionListExpression
      SD.LLBLGen.Pro.LinqSupportClasses.ExpressionClasses.SetExpression