Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CopyTo() [2/2]

FileInfo System.IO.FileInfo.CopyTo ( string destFileName,
bool overwrite )
inline

Definition at line 87 of file FileInfo.cs.

88 {
89 if (destFileName == null)
90 {
91 throw new ArgumentNullException("destFileName", SR.ArgumentNull_FileName);
92 }
93 if (destFileName.Length == 0)
94 {
95 throw new ArgumentException(SR.Argument_EmptyFileName, "destFileName");
96 }
97 string fullPath = Path.GetFullPath(destFileName);
98 FileSystem.CopyFile(FullPath, fullPath, overwrite);
99 return new FileInfo(fullPath, null, null, isNormalized: true);
100 }
FileInfo(string fileName)
Definition FileInfo.cs:54

References System.IO.FileInfo.FileInfo(), System.SR.Argument_EmptyFileName, System.SR.ArgumentNull_FileName, System.IO.FileSystem.CopyFile(), System.IO.FileSystemInfo.FullPath, and System.IO.Path.GetFullPath().