|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--stomp.util.FileManager
provides utilities for reading and writing files to disk
Constructor Summary | |
FileManager()
|
Method Summary | |
static void |
compile(java.util.Collection files)
compiles all of the files in the list at one time |
static void |
compile(java.lang.String file)
execs and waits for a new Process, javac file |
static void |
findFilesEndingWith(java.io.File root,
java.io.File current,
java.util.Collection resultsSoFar,
java.lang.String ending)
for more advanced searches... |
static java.lang.String[] |
findFilesEndingWith(java.lang.String ending)
|
static java.lang.String |
getClassFileName(java.lang.String name)
|
static java.lang.String |
getDirectoryName(java.io.File file)
returns the name of the directory that this is in / represents. |
static java.lang.StringBuffer |
getFile(java.lang.String location)
|
static java.io.File |
getJavaRootFile()
|
static java.lang.String |
getPackageName(java.io.File theFile)
returns a "." delimited description of the directory path from FileManager.JAVA_ROOT to the given file. |
static java.util.Properties |
getProperties(java.lang.String propertyFileName)
returns a Properties object that has been initialized to the contents of the given propertyFile, findable someplace on the CLASSPATH. |
static java.lang.String |
getROOT()
|
static java.lang.StringBuffer |
readFile(java.io.File theFile)
|
static java.lang.StringBuffer |
readFile(java.lang.String location)
reads in the given file and returns its contents in a StringBuffer |
static java.lang.StringBuffer |
readFile(java.lang.String location,
boolean useRoot)
reads in the given file and returns its contents in a StringBuffer. |
static void |
writeFile(java.lang.String location,
java.lang.String contents)
|
static void |
writeFile(java.lang.String location,
java.lang.String contents,
boolean useRoot)
writes the given StringBuffer to the given file location, overwriting anything that is already there. |
static void |
writeFile(java.lang.String location,
java.lang.String contents,
boolean useRoot,
boolean temp)
|
static void |
writeFile(java.lang.String location,
java.lang.StringBuffer string)
writes the given StringBuffer to given file location, regardless of whether or not there is something there already |
static void |
writeTempFile(java.lang.String location,
java.lang.String contents)
writes the given information to a temporary file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public FileManager()
Method Detail |
public static java.io.File getJavaRootFile()
public static java.lang.String getROOT()
public static java.lang.StringBuffer getFile(java.lang.String location) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.lang.StringBuffer readFile(java.lang.String location) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.lang.StringBuffer readFile(java.lang.String location, boolean useRoot) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.lang.StringBuffer readFile(java.io.File theFile) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void writeFile(java.lang.String location, java.lang.StringBuffer string) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void writeFile(java.lang.String location, java.lang.String contents) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
( String location, StringBuffer string );
public static void writeFile(java.lang.String location, java.lang.String contents, boolean useRoot) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void writeFile(java.lang.String location, java.lang.String contents, boolean useRoot, boolean temp) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void writeTempFile(java.lang.String location, java.lang.String contents) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void compile(java.lang.String file) throws java.io.IOException, java.lang.InterruptedException
java.io.IOException
java.lang.InterruptedException
public static void compile(java.util.Collection files) throws java.io.IOException, java.lang.InterruptedException
java.io.IOException
java.lang.InterruptedException
public static java.lang.String[] findFilesEndingWith(java.lang.String ending)
public static void findFilesEndingWith(java.io.File root, java.io.File current, java.util.Collection resultsSoFar, java.lang.String ending)
public static java.lang.String getClassFileName(java.lang.String name)
public static java.lang.String getDirectoryName(java.io.File file)
public static java.util.Properties getProperties(java.lang.String propertyFileName) throws java.io.IOException
java.io.IOException
public static java.lang.String getPackageName(java.io.File theFile)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |