1
0
Fork 0
mirror of https://github.com/Sonarr/Sonarr synced 2024-12-26 09:47:39 +00:00
Sonarr/NzbDrone.SqlCe/SqlCeProxy.cs
2013-02-16 13:10:20 -08:00

25 lines
574 B
C#

using System.Data.Common;
using System.Data.SqlServerCe;
using System.IO;
namespace NzbDrone.SqlCe
{
public class SqlCeProxy
{
public void EnsureDatabase(string constr)
{
var connection = new SqlCeConnection(constr);
if (!File.Exists(connection.Database))
{
var engine = new SqlCeEngine(constr);
engine.CreateDatabase();
}
}
public DbProviderFactory GetSqlCeProviderFactory()
{
return new SqlCeProviderFactory();
}
}
}