|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ops4j.io.FileUtils
public final class FileUtils
Utility methods for manipulation of Files.
Method Summary | |
---|---|
static void |
copyFile(File src,
File dest,
StreamMonitor monitor)
Copies a file. |
static boolean |
delete(File file)
Deletes the file or recursively deletes a directory depending on the file passed. |
static File |
getFileFromClasspath(String filePath)
Searches the classpath for the file denoted by the file path and returns the corresponding file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static void copyFile(File src, File dest, StreamMonitor monitor) throws IOException, FileNotFoundException
src
- The source file.dest
- The destination file.monitor
- The monitor to use for reporting.
IOException
- if any underlying I/O problem occurs.
FileNotFoundException
- if the source file does not exist.public static File getFileFromClasspath(String filePath) throws FileNotFoundException
filePath
- path to the file
FileNotFoundException
- if the file cannot be foundpublic static boolean delete(File file)
file
- file or directory to be deleted.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |