Пример #1
0
 /// <summary>
 /// Copies the file to another directory
 /// </summary>
 /// <param name="directory">Directory to copy the file to</param>
 /// <param name="overwrite">Should the file overwrite another file if found</param>
 /// <returns>The newly created file</returns>
 public Task <IFile?> CopyToAsync(IDirectory directory, bool overwrite)
 {
     if (directory is null || !Exists || InternalFile is null)
     {
         return(Task.FromResult <IFile?>(null));
     }
     return(InternalFile.CopyToAsync(directory, overwrite));
 }