|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.continuent.tungsten.common.commands.DirectoryCommands
public class DirectoryCommands
Commands to assist in directory manipulation
| Constructor Summary | |
|---|---|
DirectoryCommands()
|
|
| Method Summary | |
|---|---|
static void |
copyFile(java.lang.String srcPath,
java.lang.String destPath)
Copy a file on the local filesystem |
static boolean |
deleteDirectory(java.lang.String path)
Removes the given directory and any sub directories. |
static boolean |
deleteFile(java.lang.String filePath)
Deletes a file |
static boolean |
deleteFiles(java.lang.String directoryPath)
Deletes files in a directory matching a specific pattern |
static boolean |
exists(java.lang.String path)
Checks if the path given exists. |
static java.util.List<java.lang.String> |
fileList(java.lang.String directoryPath,
boolean includeFullPath)
Returns a listing of files in a directory matching a pattern. |
static boolean |
isDirectory(java.lang.String path)
Checks if the given path is a directory |
static boolean |
isFile(java.lang.String path)
Checks if the given path is a file |
static boolean |
mkdir(java.lang.String path)
Creates a directory |
static boolean |
mkdirs(java.lang.String path)
Creates a directory and any subdirectories |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DirectoryCommands()
| Method Detail |
|---|
public static boolean isDirectory(java.lang.String path)
path - the path to check if its a directory
public static boolean isFile(java.lang.String path)
path - the path to check if its a file
public static boolean exists(java.lang.String path)
path - the path to check
public static boolean mkdir(java.lang.String path)
path - the path to create
public static boolean mkdirs(java.lang.String path)
path - the path to create, will also create any subdirectories
public static boolean deleteDirectory(java.lang.String path)
path - remove this directory and any sub directories
public static boolean deleteFiles(java.lang.String directoryPath)
directoryPath - the directory to delete files inpublic static boolean deleteFile(java.lang.String filePath)
filePath - the file to delete
public static java.util.List<java.lang.String> fileList(java.lang.String directoryPath,
boolean includeFullPath)
directoryPath - the directory to get a file listing of;
listingPattern the pattern to search for in the file listing
public static void copyFile(java.lang.String srcPath,
java.lang.String destPath)
throws java.lang.Exception
srcPath - the source filedestPath - where the file should be copied to
java.lang.Exception - if there was a problem copying the file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||