|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sourceforge.anttestsetgen.AntTestSetGenUtil
The AntTestSetGenUtil class contains a number of simple utility functions.
| Constructor Summary | |
AntTestSetGenUtil()
|
|
| Method Summary | |
static java.lang.String |
convertPackageToPath(java.lang.String destination,
java.lang.String packageName)
Convert a Java package name to a full path name. |
static boolean |
directoryExists(java.lang.String path)
Check if a path exists Either '/' or '\' should be used as a path seperator. |
static boolean |
fileExists(java.lang.String fileName)
Check if a file exists in the file system. |
static boolean |
mkdirs(java.lang.String path)
Create one or more directories. |
static java.lang.String |
readFile(java.lang.String fileName)
Read a file from disk and place the content in a String. |
static boolean |
removeDirectory(java.lang.String path)
Remove one or more directories Either '/' or '\' should be used as a path seperator. |
static void |
removeFile(java.lang.String fileName)
Remove a file from the file system. |
static java.lang.String |
requiredCheck(java.lang.String name,
java.lang.String value)
Check if a required property is set. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public AntTestSetGenUtil()
| Method Detail |
public static java.lang.String readFile(java.lang.String fileName)
fileName - The name of the file (should be in the classpath)
java.lang.RuntimeException - In case there is an error loading the file.public static boolean mkdirs(java.lang.String path)
path - The name of the path to be created
public static boolean removeDirectory(java.lang.String path)
path - The name of the path to be created
public static boolean directoryExists(java.lang.String path)
path - The name of the path to be created
public static java.lang.String convertPackageToPath(java.lang.String destination,
java.lang.String packageName)
destination - The orginating destinationpackageName - The Java package name
public static void removeFile(java.lang.String fileName)
fileName - The name of the file to be removed.public static boolean fileExists(java.lang.String fileName)
fileName - The name of the file to be removed.
public static java.lang.String requiredCheck(java.lang.String name,
java.lang.String value)
name - The name of the required property.value - The current value of the required property
org.apache.tools.ant.BuildException - In case the value is null
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||