2012-08-13 10:04:31 -01:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.IO;
|
2012-11-08 08:27:38 +05:00
|
|
|
|
using Umbraco.Core.CodeAnnotations;
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Core.IO
|
|
|
|
|
|
{
|
2012-11-08 08:27:38 +05:00
|
|
|
|
[UmbracoExperimentalFeature("http://issues.umbraco.org/issue/U4-1156", "Will be declared public after 4.10")]
|
2013-01-02 14:28:15 -01:00
|
|
|
|
internal interface IFileSystem
|
2012-08-13 10:04:31 -01:00
|
|
|
|
{
|
2012-08-14 09:11:49 -01:00
|
|
|
|
IEnumerable<string> GetDirectories(string path);
|
|
|
|
|
|
|
2012-08-13 10:04:31 -01:00
|
|
|
|
void DeleteDirectory(string path);
|
|
|
|
|
|
|
|
|
|
|
|
void DeleteDirectory(string path, bool recursive);
|
|
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
bool DirectoryExists(string path);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
|
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
void AddFile(string path, Stream stream);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
void AddFile(string path, Stream stream, bool overrideIfExists);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
IEnumerable<string> GetFiles(string path);
|
|
|
|
|
|
|
|
|
|
|
|
IEnumerable<string> GetFiles(string path, string filter);
|
|
|
|
|
|
|
|
|
|
|
|
Stream OpenFile(string path);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
|
|
|
|
|
void DeleteFile(string path);
|
|
|
|
|
|
|
|
|
|
|
|
bool FileExists(string path);
|
|
|
|
|
|
|
2012-08-20 09:42:32 -01:00
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
string GetRelativePath(string fullPathOrUrl);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
string GetFullPath(string path);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
2012-08-14 09:11:49 -01:00
|
|
|
|
string GetUrl(string path);
|
2012-08-13 10:04:31 -01:00
|
|
|
|
|
|
|
|
|
|
DateTimeOffset GetLastModified(string path);
|
|
|
|
|
|
|
|
|
|
|
|
DateTimeOffset GetCreated(string path);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|