public class FileUtils
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static void |
deleteFile(java.io.File file)
Delete a file or folder and all of it's contents.
|
static void |
deleteFile(java.lang.String path)
Delete a file.
|
static java.io.File |
getFile(java.lang.String filename)
Find the file with the given name.
|
static int |
getLineCount(java.io.File file)
Determine how many lines are in the file.
|
static void |
moveFile(java.io.File source,
java.io.File dest)
Moves a file.
|
public static void deleteFile(java.io.File file) throws java.io.IOException
file
- The file to be deleted.java.io.IOException
public static void deleteFile(java.lang.String path) throws java.io.IOException
path
- Path to the file to be deleted.java.io.IOException
public static void moveFile(java.io.File source, java.io.File dest)
source
- The file to be moved.dest
- The destination file.public static int getLineCount(java.io.File file) throws java.io.IOException
file
- java.io.IOException
public static java.io.File getFile(java.lang.String filename)
filename
-