org.unitils.util
Class FileUtils

java.lang.Object
  extended by org.unitils.util.FileUtils

public class FileUtils
extends Object


Constructor Summary
FileUtils()
           
 
Method Summary
static void copyClassPathResource(String classPathResourceName, String fileSystemDirectoryName)
           
static URL getUrl(File file)
          Creates an URL that points to the given file.
static void writeStringToFile(File file, String string)
          Writes the given string to the given file
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileUtils

public FileUtils()
Method Detail

copyClassPathResource

public static void copyClassPathResource(String classPathResourceName,
                                         String fileSystemDirectoryName)

getUrl

public static URL getUrl(File file)
Creates an URL that points to the given file.

Parameters:
file - The file, not null
Returns:
The URL to the file, not null

writeStringToFile

public static void writeStringToFile(File file,
                                     String string)
                              throws IOException
Writes the given string to the given file

Parameters:
file - the file to write, not null
string - the string, not null
Throws:
IOException


Copyright © 2011. All Rights Reserved.