2020-03-24 13:01:14 +01:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Threading.Tasks;
|
2020-05-04 12:48:27 +02:00
|
|
|
|
using ModernKeePass.Domain.Dtos;
|
2020-03-24 13:01:14 +01:00
|
|
|
|
|
|
|
|
|
namespace ModernKeePass.Application.Common.Interfaces
|
|
|
|
|
{
|
|
|
|
|
public interface IFileProxy
|
|
|
|
|
{
|
2020-05-04 12:48:27 +02:00
|
|
|
|
Task<FileInfo> OpenFile(string name, string extension, bool addToRecent);
|
|
|
|
|
Task<FileInfo> CreateFile(string name, string extension, string description, bool addToRecent);
|
|
|
|
|
Task<byte[]> ReadBinaryFile(string path);
|
|
|
|
|
Task<IList<string>> ReadTextFile(string path);
|
2020-03-24 13:01:14 +01:00
|
|
|
|
Task WriteBinaryContentsToFile(string path, byte[] contents);
|
|
|
|
|
void ReleaseFile(string path);
|
|
|
|
|
}
|
|
|
|
|
}
|