public Entities.File GetFile(string id) { var fullPath = Directory.GetFiles(BaseDirectory).FirstOrDefault(f => f.Contains(id)); var file = new Entities.File(BaseDirectory, fullPath); return(file); }
public Entities.File GetFile(string guidFileName, string fileExtension) { Entities.File file = new Entities.File(); file.FileName = guidFileName; file.FileExtension = fileExtension; file.Data = File.ReadAllBytes(BaseDirectory + guidFileName + fileExtension); return(file); }