net.loadbang.util
Class FileUtils

java.lang.Object
  extended by net.loadbang.util.FileUtils

public class FileUtils
extends java.lang.Object

Some library utilities over files.


Constructor Summary
FileUtils()
           
 
Method Summary
static java.lang.String getExtension00(java.lang.String file)
          Determine the extension of a filename (or even something more complicated, like a URL).
static java.io.File locateFile(java.lang.String file)
          Return a File object for a file on the Max search path, or fail assertion if it's not found.
static java.io.File locateFile00(java.lang.String file)
          Return the File object for a file in the Max search path.
static java.lang.String stripExtension(java.lang.String file)
          Strip any extension from a filename.
 
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

locateFile00

public static java.io.File locateFile00(java.lang.String file)
Return the File object for a file in the Max search path.

Parameters:
file - The unqualified file name.
Returns:
a File object for the file, or null if file not found in the search path.

locateFile

public static java.io.File locateFile(java.lang.String file)
Return a File object for a file on the Max search path, or fail assertion if it's not found.


stripExtension

public static java.lang.String stripExtension(java.lang.String file)
Strip any extension from a filename.

Parameters:
file - the file name
Returns:
the file name with any extension stripped.

getExtension00

public static java.lang.String getExtension00(java.lang.String file)
Determine the extension of a filename (or even something more complicated, like a URL). Does not include the leading ".".