mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-11-01 08:22:35 +01:00
30 lines
562 B
C#
30 lines
562 B
C#
using System.Linq;
|
|
|
|
namespace NzbDrone.Core.Instrumentation
|
|
{
|
|
public interface ILogService
|
|
{
|
|
void DeleteAll();
|
|
void Trim();
|
|
}
|
|
|
|
public class LogService : ILogService
|
|
{
|
|
private readonly ILogRepository _logRepository;
|
|
|
|
public LogService(ILogRepository logRepository)
|
|
{
|
|
_logRepository = logRepository;
|
|
}
|
|
|
|
public void DeleteAll()
|
|
{
|
|
_logRepository.Purge();
|
|
}
|
|
|
|
public void Trim()
|
|
{
|
|
_logRepository.Trim();
|
|
}
|
|
}
|
|
} |