1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-09-22 17:31:47 +02:00
Radarr/NzbDrone.Core/Providers/DiskProvider.cs
markus101 88ad555e75 Delete is setup, just need to add a link to follow through on the delete.
Removes EpisodeFiles, Episodes, Season and then the Series.
2011-02-17 22:49:23 -08:00

47 lines
1.0 KiB
C#

using System;
using System.IO;
namespace NzbDrone.Core.Providers
{
public class DiskProvider : IDiskProvider
{
#region IDiskProvider Members
public bool FolderExists(string path)
{
return Directory.Exists(path);
}
public bool FileExists(string path)
{
return File.Exists(path);
}
public string[] GetDirectories(string path)
{
return Directory.GetDirectories(path);
}
public string[] GetFiles(string path, string pattern, SearchOption searchOption)
{
return Directory.GetFiles(path, pattern, searchOption);
}
public long GetSize(string path)
{
return new FileInfo(path).Length;
}
public String CreateDirectory(string path)
{
return Directory.CreateDirectory(path).FullName;
}
public void DeleteFile(string path)
{
File.Delete(path);
}
#endregion
}
}