|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.pebble.util.FileUtils
public final class FileUtils
A collection of utility methods for manipulating files.
| Constructor Summary | |
|---|---|
FileUtils()
|
|
| Method Summary | |
|---|---|
static void |
copyFile(java.io.File source,
java.io.File destination)
Copies a file. |
static void |
deleteFile(java.io.File directory)
Deletes a file, including all files and sub-directories if the specified file is a directory. |
static java.lang.String |
getContentType(java.lang.String name)
Gets the content type for the specified filename. |
static boolean |
underneathRoot(java.io.File root,
java.io.File file)
Determines whether a given file is underneath a given root. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FileUtils()
| Method Detail |
|---|
public static boolean underneathRoot(java.io.File root,
java.io.File file)
root - the root directoryfile - the file to test
public static void deleteFile(java.io.File directory)
directory - a File instance representing the directory to delete
public static void copyFile(java.io.File source,
java.io.File destination)
throws java.io.IOException
source - the source Filedestination - the destination File
java.io.IOExceptionpublic static java.lang.String getContentType(java.lang.String name)
name - the name of a file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||