JTools

org.jtools.io
Class DirectoryOperations

java.lang.Object
  extended by org.jtools.io.DirectoryOperations

public final class DirectoryOperations
extends Object

a simple helper class for directory operations (typically mkdir).


Constructor Summary
DirectoryOperations()
           
 
Method Summary
static File createTempFile(String prefix, String suffix, File dir)
          creates a temp file with respect to the singleton mutex.
static Object getMutex()
          gets a mutex singleton as semaphore for mkdir operations.
static void mkdir(File dir)
          creates a directory with respect to the singleton mutex.
static void mkfiledir(File file)
          creates the hosting directory of a file with respect to the singleton mutex.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DirectoryOperations

public DirectoryOperations()
Method Detail

createTempFile

public static File createTempFile(String prefix,
                                  String suffix,
                                  File dir)
                           throws IOException
creates a temp file with respect to the singleton mutex.

Throws:
IOException

getMutex

public static Object getMutex()
gets a mutex singleton as semaphore for mkdir operations.


mkdir

public static void mkdir(File dir)
creates a directory with respect to the singleton mutex.


mkfiledir

public static void mkfiledir(File file)
creates the hosting directory of a file with respect to the singleton mutex.


JTools

© 2000-2006, JTools.org.