removed sqlce

This commit is contained in:
kay.one
2013-03-02 10:25:39 -08:00
parent b76c6329fe
commit beb2f7c7fd
105 changed files with 410 additions and 5340 deletions

View File

@@ -3,7 +3,7 @@ using System.Linq;
namespace NzbDrone.Core.Datastore
{
public interface IBasicRepository<TModel>
public interface IBasicRepository<TModel> where TModel : ModelBase, new()
{
IEnumerable<TModel> All();
int Count();
@@ -15,6 +15,7 @@ namespace NzbDrone.Core.Datastore
IList<TModel> InsertMany(IList<TModel> model);
IList<TModel> UpdateMany(IList<TModel> model);
void Purge();
bool HasItems();
}
public class BasicRepository<TModel> : IBasicRepository<TModel> where TModel : ModelBase, new()
@@ -90,5 +91,10 @@ namespace NzbDrone.Core.Datastore
{
DeleteMany(Queryable.Select(c => c.Id));
}
public bool HasItems()
{
return Queryable.Any();
}
}
}