|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.cargo.util.FileUtils
FileHandler
instead
public class FileUtils
Set of common File manipulation utility methods.
Constructor Summary | |
---|---|
FileUtils()
Deprecated. |
Method Summary | |
---|---|
void |
copy(InputStream in,
OutputStream out)
Deprecated. Copies data from an InputStream to an OutputStream. |
void |
copy(InputStream in,
OutputStream out,
int bufSize)
Deprecated. Copies data from an InputStream to an OutputStream. |
File |
createDirectory(File parentDir,
String name)
Deprecated. |
File |
createDirectory(URI parentDir,
String name)
Deprecated. Convenience method for creating a new directory inside another one. |
File |
createTmpDirectory(String name)
Deprecated. Creates a temporary directory. |
File |
createUniqueTmpDirectory()
Deprecated. Creates a unique temporary directory. |
void |
delete(File item)
Deprecated. Deletes a file or directory, removing any children as appropriate. |
String |
getFilename(String filePath)
Deprecated. Convenience method that returns a relative filename and its extension from a complete file path (path, name and extension). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FileUtils()
Method Detail |
---|
public final File createDirectory(URI parentDir, String name) throws IOException
parentDir
- The directory in which the new directory should be createdname
- The name of the directory to create
IOException
- If the directory could not be createdpublic final File createDirectory(File parentDir, String name) throws IOException
IOException
createDirectory(URI, String)
public File createTmpDirectory(String name)
name
- The name of the directory to create
public final String getFilename(String filePath)
filePath
- the full file path (including relative name and extension)
public File createUniqueTmpDirectory()
public void copy(InputStream in, OutputStream out) throws IOException
in
- InputStream to copy data fromout
- OutputStream to copy data to
IOException
- if an I/O error occurspublic void copy(InputStream in, OutputStream out, int bufSize) throws IOException
in
- InputStream to copy data fromout
- OutputStream to copy data tobufSize
- size of the copy buffer
IOException
- if an I/O error occurspublic void delete(File item)
item
- in file or directory to remove
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |