webfunds.client.util
Class FileUtils
java.lang.Object
|
+--webfunds.client.util.FileUtils
- public final class FileUtils
- extends java.lang.Object
Helper functions dealing with File objects.
|
Method Summary |
static void |
copyFile(java.io.File srcFile,
java.io.File dstDir)
Copy the contents of srcFile to a file of the same name in
directory dstDir. |
static void |
copyTree(java.io.File subject,
java.io.File toDir)
Copy the file system tree denoted by subject to the directory
denoted by backupDir. |
static void |
main(java.lang.String[] argv)
|
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
copyTree
public static void copyTree(java.io.File subject,
java.io.File toDir)
throws java.io.IOException
- Copy the file system tree denoted by subject to the directory
denoted by backupDir. This method is recursive.
- Parameters:
subject - the tree (file or directory) to copytoDir - the directory to copy subject into.- Throws:
- java.io.IOException - If an error occurs.
- InternalError - If toDir is not a directory
copyFile
public static void copyFile(java.io.File srcFile,
java.io.File dstDir)
throws java.io.IOException
- Copy the contents of srcFile to a file of the same name in
directory dstDir.
- Parameters:
srcFile - the source file to copydstDir - the destination dir to copy the file into- Throws:
- java.io.IOException - for read and write errors
- InternalError - if srcFile is not a file or dstDir is not a directory
main
public static void main(java.lang.String[] argv)
throws java.io.IOException