This commit is contained in:
kay.one 2013-05-11 13:06:57 -07:00
commit 57e78e31fe
6 changed files with 71 additions and 35 deletions

View file

@ -10,12 +10,19 @@ namespace NzbDrone.Core.Datastore
public class Database : IDatabase
{
private readonly Func<IDataMapper> _dataMapperFactory;
public Database(IDataMapper dataMapper)
public Database(Func<IDataMapper> dataMapperFactory)
{
DataMapper = dataMapper;
_dataMapperFactory = dataMapperFactory;
}
public IDataMapper DataMapper { get; private set; }
public IDataMapper DataMapper
{
get
{
return _dataMapperFactory();
}
}
}
}