protected void AddFile(String addedFileName, String originalFileName, String password = null) { File.Copy($"{Settings.DataPath}{Path.DirectorySeparatorChar}{originalFileName}", $"{Settings.DataPath}{Path.DirectorySeparatorChar}{addedFileName}"); var file = new FileForTest { FileName = $"{Settings.DataPath}{Path.DirectorySeparatorChar}{addedFileName}" }; if (password != null) { file.Password = password; } Files.Add(file); }
protected void AddFile(string addedFileName, string originalFileName, LovePdf.Model.Enums.Rotate rotation, string password = null) { File.Copy($"{Settings.DataPath}{Path.DirectorySeparatorChar}{originalFileName}", $"{Settings.DataPath}{Path.DirectorySeparatorChar}{addedFileName}"); var file = new FileForTest { FileName = $"{Settings.DataPath}{Path.DirectorySeparatorChar}{addedFileName}" }; if (password != null) { file.Password = password; } file.Rotation = rotation; Files.Add(file); }