12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- using Ant.Core;
- using Ant.Core.Visitors;
- using Ant.Data;
- using Ant.DbExpressions;
- using Ant.Descriptors;
- using Ant.Entity;
- using Ant.Exceptions;
- using Ant.Infrastructure;
- using Ant.ORM;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Linq.Expressions;
- using System.Reflection;
- using System.Text;
- namespace Ant.SQLite
- {
- public class SQLiteContext : DbContext
- {
- DbContextServiceProvider _dbContextServiceProvider;
- public SQLiteContext(IDbConnectionFactory dbConnectionFactory)
- {
- Utils.CheckNull(dbConnectionFactory);
- this._dbContextServiceProvider = new DbContextServiceProvider(dbConnectionFactory);
- }
- public SQLiteContext(string connString)
- {
- }
- /// <summary>
- /// 数据库类型
- /// </summary>
- public override DatabaseType DatabaseType
- {
- get { return DatabaseType.SQLite; }
- }
- public override IDbContextServiceProvider DbContextServiceProvider
- {
- get { return this._dbContextServiceProvider; }
- }
- protected override string GetSelectLastInsertIdClause()
- {
- return "SELECT LAST_INSERT_ROWID()";
- }
- }
- }
|