/// <summary> /// Visitor pattern method for <see cref="T:System.Data.Entity.Core.Common.CommandTrees.DbJoinExpression" />. /// </summary> /// <param name="expression"> The DbJoinExpression that is being visited. </param> /// <exception cref="T:System.ArgumentNullException"> /// <paramref name="expression" /> /// is null /// </exception> public override void Visit(DbJoinExpression expression) { Check.NotNull <DbJoinExpression>(expression, nameof(expression)); this.VisitExpressionBindingPre(expression.Left); this.VisitExpressionBindingPre(expression.Right); this.VisitExpression(expression.JoinCondition); this.VisitExpressionBindingPost(expression.Left); this.VisitExpressionBindingPost(expression.Right); }
/// <summary> /// Visitor pattern method for <see cref="DbJoinExpression" />. /// </summary> /// <param name="expression"> The DbJoinExpression that is being visited. </param> /// <exception cref="ArgumentNullException"> /// <paramref name="expression" /> /// is null /// </exception> public override void Visit(DbJoinExpression expression) { Check.NotNull(expression, "expression"); VisitExpressionBindingPre(expression.Left); VisitExpressionBindingPre(expression.Right); VisitExpression(expression.JoinCondition); VisitExpressionBindingPost(expression.Left); VisitExpressionBindingPost(expression.Right); }
public override DbExpression Visit(DbJoinExpression expression) { Check.NotNull(expression, "expression"); DbExpression result = expression; var newLeft = VisitExpressionBinding(expression.Left); var newRight = VisitExpressionBinding(expression.Right); EnterScope(newLeft.Variable, newRight.Variable); var newCondition = VisitExpression(expression.JoinCondition); ExitScope(); if (!ReferenceEquals(expression.Left, newLeft) || !ReferenceEquals(expression.Right, newRight) || !ReferenceEquals(expression.JoinCondition, newCondition)) { if (DbExpressionKind.InnerJoin == expression.ExpressionKind) { result = CqtBuilder.InnerJoin(newLeft, newRight, newCondition); } else if (DbExpressionKind.LeftOuterJoin == expression.ExpressionKind) { result = CqtBuilder.LeftOuterJoin(newLeft, newRight, newCondition); } else { Debug.Assert( expression.ExpressionKind == DbExpressionKind.FullOuterJoin, "DbJoinExpression had ExpressionKind other than InnerJoin, LeftOuterJoin or FullOuterJoin?"); result = CqtBuilder.FullOuterJoin(newLeft, newRight, newCondition); } } NotifyIfChanged(expression, result); return(result); }
/// <summary> /// When overridden in a derived class, implements the visitor pattern for /// <see /// cref="T:System.Data.Entity.Core.Common.CommandTrees.DbJoinExpression" /> /// . /// </summary> /// <returns>A result value of a specific type.</returns> /// <param name="expression"> /// The <see cref="T:System.Data.Entity.Core.Common.CommandTrees.DbJoinExpression" /> that is being visited. /// </param> public abstract TResultType Visit(DbJoinExpression expression);
/// <summary> /// When overridden in a derived class, implements the visitor pattern for /// <see cref="T:System.Data.Entity.Core.Common.CommandTrees.DbJoinExpression" /> /// . /// </summary> /// <param name="expression"> /// The <see cref="T:System.Data.Entity.Core.Common.CommandTrees.DbJoinExpression" /> that is visited. /// </param> public abstract void Visit(DbJoinExpression expression);
public override void Visit(DbJoinExpression expression) { }