Class SqlTableSource
public class SqlTableSource : ISqlTableSource, ISqlExpression, IQueryElement, IEquatable<ISqlExpression>, ISqlExpressionWalkable
- Inheritance
-
SqlTableSource
- Implements
- Extension Methods
Constructors
SqlTableSource(ISqlTableSource, string?)
public SqlTableSource(ISqlTableSource source, string? alias)
Parameters
source
ISqlTableSourcealias
string
SqlTableSource(ISqlTableSource, string?, params SqlJoinedTable[]?)
public SqlTableSource(ISqlTableSource source, string? alias, params SqlJoinedTable[]? joins)
Parameters
source
ISqlTableSourcealias
stringjoins
SqlJoinedTable[]
SqlTableSource(ISqlTableSource, string?, IEnumerable<SqlJoinedTable>, IEnumerable<ISqlExpression[]>?)
public SqlTableSource(ISqlTableSource source, string? alias, IEnumerable<SqlJoinedTable> joins, IEnumerable<ISqlExpression[]>? uniqueKeys)
Parameters
source
ISqlTableSourcealias
stringjoins
IEnumerable<SqlJoinedTable>uniqueKeys
IEnumerable<ISqlExpression[]>
Properties
Alias
public string? Alias { get; set; }
Property Value
All
public SqlField All { get; }
Property Value
CanBeNull
public bool CanBeNull { get; }
Property Value
ElementType
public QueryElementType ElementType { get; }
Property Value
HasUniqueKeys
public bool HasUniqueKeys { get; }
Property Value
this[ISqlTableSource]
public SqlTableSource? this[ISqlTableSource table] { get; }
Parameters
table
ISqlTableSource
Property Value
this[ISqlTableSource, string?]
public SqlTableSource? this[ISqlTableSource table, string? alias] { get; }
Parameters
table
ISqlTableSourcealias
string
Property Value
Joins
public List<SqlJoinedTable> Joins { get; }
Property Value
Precedence
public int Precedence { get; }
Property Value
Source
public ISqlTableSource Source { get; set; }
Property Value
SourceID
public int SourceID { get; }
Property Value
SqlTableType
public SqlTableType SqlTableType { get; }
Property Value
SystemType
public Type? SystemType { get; }
Property Value
UniqueKeys
Contains list of columns that build unique key for Source. Used in JoinOptimizer for safely removing sub-query from resulting SQL.
public List<ISqlExpression[]> UniqueKeys { get; }
Property Value
Methods
Deconstruct(out ISqlTableSource)
public void Deconstruct(out ISqlTableSource source)
Parameters
source
ISqlTableSource
Equals(ISqlExpression, Func<ISqlExpression, ISqlExpression, bool>)
public bool Equals(ISqlExpression other, Func<ISqlExpression, ISqlExpression, bool> comparer)
Parameters
other
ISqlExpressioncomparer
Func<ISqlExpression, ISqlExpression, bool>
Returns
ForEach<TContext>(TContext, Action<TContext, SqlTableSource>, HashSet<SelectQuery>)
public void ForEach<TContext>(TContext context, Action<TContext, SqlTableSource> action, HashSet<SelectQuery> visitedQueries)
Parameters
context
TContextaction
Action<TContext, SqlTableSource>visitedQueries
HashSet<SelectQuery>
Type Parameters
TContext
GetJoinNumber()
public int GetJoinNumber()
Returns
GetTables()
public IEnumerable<ISqlTableSource> GetTables()
Returns
Walk<TContext>(WalkOptions, TContext, Func<TContext, ISqlExpression, ISqlExpression>)
public ISqlExpression Walk<TContext>(WalkOptions options, TContext context, Func<TContext, ISqlExpression, ISqlExpression> func)
Parameters
options
WalkOptionscontext
TContextfunc
Func<TContext, ISqlExpression, ISqlExpression>
Returns
Type Parameters
TContext