public BinaryExpression ToEqualExpression(object obj, TableExpression table = null) { var value = GetValue(obj); return Expression.MakeBinary(ExpressionType.Equal, ToColumnExpression(table), Expression.Constant(value)); }
public ColumnExpression(string columnName, TableExpression table, Type type) : base(ExpressionType.Constant, type) { ColumnName = new ObjectNameExpression(columnName); Table = table; }
public ColumnExpression ToColumnExpression(TableExpression table = null, Type type = null) { if (type == null) type = PropertyName == null ? typeof (Type) : DeclaringTypes[0].GetProperty(PropertyName).PropertyType; return new ColumnExpression(ColumnName, table, type); }
public CreateIndexExpression(string name, TableExpression table) { Name = name; Table = table; }
public DropTableExpression(TableExpression table) { Table = table; }
public CreateTableExpression(TableExpression table) { Table = table; }
public AlterTableExpression(TableExpression table) : base(table) { }
public JoinExpression(JoinType joinType, TableExpression table = null) { JoinType = joinType; Table = table; }
protected virtual Expression VisitTable(TableExpression node) { var pattern = _useAliases ? "{0} {1}" : "{0}"; Append(string.Format(pattern, node.Table.FullNameWithBrackets, node.Alias)); return node; }