/// <summary></summary> /// <param name="left"></param> /// <param name="type"></param> /// <param name="right"></param> /// <param name="onStatement"></param> public PpsJoinExpression(PpsExpressionPart left, PpsDataJoinType type, PpsExpressionPart right, PpsDataJoinStatement[] onStatement) { this.left = left ?? throw new ArgumentNullException(nameof(left)); this.type = type; this.right = right ?? throw new ArgumentNullException(nameof(right)); this.onStatement = onStatement ?? throw new ArgumentNullException(nameof(onStatement)); } // ctor
/// <summary>Visit expression part</summary> /// <param name="expr"></param> /// <returns></returns> public TRESULT Visit(PpsExpressionPart expr) { switch (expr) { case PpsTableExpression tableExpr: return(CreateTableStatement(tableExpr.Table, tableExpr.Alias)); case PpsJoinExpression joinExpr: return(CreateJoinStatement(Visit(joinExpr.Left), joinExpr.Type, Visit(joinExpr.Right), joinExpr.Statement)); default: throw new InvalidOperationException(); } } // func Visit
/// <summary></summary> /// <param name="part"></param> protected PpsDataJoinExpression(PpsExpressionPart part) => root = part ?? throw new ArgumentNullException(nameof(part));