123456789101112131415161718192021222324252627282930313233343536 |
- using Ant.Common;
- using Ant.Utility;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- namespace Ant.DbExpressions
- {
- public class DbInsertExpression : DbExpression
- {
- DbTable _table;
- Dictionary<DbColumn, DbExpression> _insertColumns;
- public DbInsertExpression(DbTable table)
- : base(DbExpressionType.Insert, UtilConstants.TypeOfVoid)
- {
- AntUtils.CheckNull(table);
- this._table = table;
- this._insertColumns = new Dictionary<DbColumn, DbExpression>();
- }
- /// <summary>
- /// 表名
- /// </summary>
- public DbTable Table { get { return this._table; } }
- /// <summary>
- /// 组装插入SQL语句的列
- /// </summary>
- public Dictionary<DbColumn, DbExpression> InsertColumns { get { return this._insertColumns; } }
- public override T Accept<T>(DbExpressionVisitor<T> visitor)
- {
- return visitor.Visit(this);
- }
- }
- }
|