mirror of
https://github.com/DapperLib/Dapper.git
synced 2026-10-19 23:28:15 +08:00
78ed4b2077
One of several moves to make this something we can dev on all platforms and build on Actions for v3 onwards.
35 lines
1.0 KiB
C#
35 lines
1.0 KiB
C#
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using LinqToDB.Configuration;
|
|
|
|
namespace Dapper.Tests.Performance.Linq2Db
|
|
{
|
|
public class Linq2DBSettings : ILinqToDBSettings
|
|
{
|
|
private readonly string _connectionString;
|
|
public IEnumerable<IDataProviderSettings> DataProviders => Enumerable.Empty<IDataProviderSettings>();
|
|
|
|
public string DefaultConfiguration => "SqlServer";
|
|
public string DefaultDataProvider => "SqlServer";
|
|
|
|
public Linq2DBSettings(string connectionString)
|
|
{
|
|
_connectionString = connectionString;
|
|
}
|
|
|
|
public IEnumerable<IConnectionStringSettings> ConnectionStrings
|
|
{
|
|
get
|
|
{
|
|
yield return
|
|
new ConnectionStringSettings
|
|
{
|
|
Name = "SqlServer",
|
|
ProviderName = "SqlServer",
|
|
ConnectionString = _connectionString
|
|
};
|
|
}
|
|
}
|
|
}
|
|
}
|