/// <summary> /// 获取DB选择器 /// </summary> /// <param name="type">数据库类型</param> /// <returns>选择器</returns> public static IDbSelector GetDbSelector(MyDbType type) { IDbSelector selector = null; switch (type) { case MyDbType.None: break; case MyDbType.Oracle: selector = new OracleDbSelector(); break; case MyDbType.MySql: selector = new MySqlDbSelector(); break; case MyDbType.SqlServer: selector = new SqlServerDbSelector(); break; default: break; } return(selector); }
/// <summary> /// 获取DB选择器 /// </summary> /// <param name="type">数据库类型</param> /// <returns>选择器</returns> public static IDbSelector GetDbSelector(MyDbType type) { IDbSelector selector = null; switch (type) { case MyDbType.None: break; case MyDbType.Oracle: selector = new OracleDbSelector(); break; case MyDbType.MySql: selector = new MySqlDbSelector(); break; case MyDbType.SqlServer: selector = new SqlServerDbSelector(); break; default: break; } return selector; }