view Source/Data/Linq/Builder/IBuildContext.cs @ 9:1e85f66cf767 default tip

update bltoolkit
author nickolay
date Thu, 05 Apr 2018 20:53:26 +0300
parents f990fcb411a9
children
line wrap: on
line source

using System;
using System.Linq.Expressions;

#if DEBUG
#pragma warning disable 3010
#endif

namespace BLToolkit.Data.Linq.Builder
{
	using Data.Sql;

	public interface IBuildContext
	{
#if DEBUG
// ReSharper disable InconsistentNaming
		[CLSCompliant(false)]
		string _sqlQueryText { get; }
// ReSharper restore InconsistentNaming
#endif

		ExpressionBuilder  Builder    { get; }
		Expression         Expression { get; }
		SqlQuery           SqlQuery   { get; set; }
		IBuildContext      Parent     { get; set; }

		void               BuildQuery<T>       (Query<T> query, ParameterExpression queryParameter);
		Expression         BuildExpression     (Expression expression, int level);
		SqlInfo[]          ConvertToSql        (Expression expression, int level, ConvertFlags flags);
		SqlInfo[]          ConvertToIndex      (Expression expression, int level, ConvertFlags flags);
		IsExpressionResult IsExpression        (Expression expression, int level, RequestFor requestFlag);
		IBuildContext      GetContext          (Expression expression, int level, BuildInfo buildInfo);
		int                ConvertToParentIndex(int index, IBuildContext context);
		void               SetAlias            (string alias);
		ISqlExpression     GetSubQuery         (IBuildContext context);
	}
}