public final class Directory
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
BUFFER_SIZE
Default buffer size for read/write operations.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
copyFile(java.io.File source,
java.io.File target)
Copy the specified file.
|
static boolean |
deleteDirectory(java.io.File path)
Delete a directory and all children.
|
static java.lang.String |
readStream(java.io.InputStream is)
Read the entire contents of a stream into a string.
|
static java.lang.String |
readTextFile(java.lang.String filename)
Read the entire contents of a stream into a string.
|
public static final int BUFFER_SIZE
public static void copyFile(java.io.File source,
java.io.File target)
source - The file to copy.target - The target of the copy.public static boolean deleteDirectory(java.io.File path)
path - The path to delete.public static java.lang.String readStream(java.io.InputStream is)
is - The input stream to read from.public static java.lang.String readTextFile(java.lang.String filename)
filename - The input stream to read from.