|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.codehaus.mojo.hibernate3.HibernateUtils
public final class HibernateUtils
Utility class.
| Constructor Summary | |
|---|---|
HibernateUtils()
|
|
| Method Summary | |
|---|---|
static Object |
getClass(String className)
Returns an instance of a class or else return a null. |
static Object |
getClass(String className,
Class caller)
|
static Object |
getClass(String className,
String defaultClassName)
Returns an instance of a class or if not found a default one. |
static File |
getFile(File path,
String filePath)
Returns a File object if the file exists and is a file or a null if it doesn't meet the criteria. |
static String |
getJavaVersion()
Returns "1.5" if the java.version system property starts with 1.5 or 1.6. |
static String |
getPath(File path,
String filePath)
Returns a path of *only* of a file that exists. |
static File |
prepareDirectory(File directory,
String parameter)
Checks if the directory is in fact a directory path and creates it if it is necessary. |
static File |
prepareDirectory(File parent,
String directoryPath,
String parameter)
Checks if the directory is in fact a directory path and creates it if it is necessary. |
static File |
prepareFile(File parent,
String filePath,
String parameter)
Checks if the file is a file path and creates the directories needed to create the file if it is necessary. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HibernateUtils()
| Method Detail |
|---|
public static String getJavaVersion()
public static Object getClass(String className,
String defaultClassName)
className - class to look fordefaultClassName - default class to return
public static Object getClass(String className)
className - class to return
public static Object getClass(String className,
Class caller)
public static File getFile(File path,
String filePath)
path - parent pathfilePath - file path
public static String getPath(File path,
String filePath)
path - parent pathfilePath - file path
public static File prepareDirectory(File parent,
String directoryPath,
String parameter)
throws MojoExecutionException
parent - parent filedirectoryPath - child directory pathparameter - name of the parameter calling this method
MojoExecutionException - if the directory is not a directory
public static File prepareDirectory(File directory,
String parameter)
throws MojoExecutionException
directory - child directoryparameter - name of the parameter calling this method
MojoExecutionException - if the directory is not a directory
public static File prepareFile(File parent,
String filePath,
String parameter)
throws MojoExecutionException
parent - parent filefilePath - child file pathparameter - name of the parameter calling this method
MojoExecutionException - if the file is not a file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||