FileIOProvider.cs 455 B

12345678910111213141516171819202122
  1. using System.IO;
  2. using System.Text;
  3. namespace Packages.Rider.Editor.ProjectGeneration {
  4. class FileIOProvider : IFileIO
  5. {
  6. public bool Exists(string fileName)
  7. {
  8. return File.Exists(fileName);
  9. }
  10. public string ReadAllText(string fileName)
  11. {
  12. return File.ReadAllText(fileName);
  13. }
  14. public void WriteAllText(string fileName, string content)
  15. {
  16. File.WriteAllText(fileName, content, Encoding.UTF8);
  17. }
  18. }
  19. }