|
||||||||||
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 java.lang.Object |
getClass(java.lang.String className)
Returns an instance of a class or else return a null. |
static java.lang.Object |
getClass(java.lang.String className,
java.lang.Class caller)
|
static java.lang.Object |
getClass(java.lang.String className,
java.lang.String defaultClassName)
Returns an instance of a class or if not found a default one. |
static java.io.File |
getFile(java.io.File path,
java.lang.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 java.lang.String |
getJavaVersion()
Returns "1.5" if the java.version system property starts with 1.5 or 1.6. |
static java.lang.String |
getPath(java.io.File path,
java.lang.String filePath)
Returns a path of *only* of a file that exists. |
static java.io.File |
prepareDirectory(java.io.File directory,
java.lang.String parameter)
Checks if the directory is in fact a directory path and creates it if it is necessary. |
static java.io.File |
prepareDirectory(java.io.File parent,
java.lang.String directoryPath,
java.lang.String parameter)
Checks if the directory is in fact a directory path and creates it if it is necessary. |
static java.io.File |
prepareFile(java.io.File parent,
java.lang.String filePath,
java.lang.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 java.lang.String getJavaVersion()
public static java.lang.Object getClass(java.lang.String className, java.lang.String defaultClassName)
className
- class to look fordefaultClassName
- default class to return
public static java.lang.Object getClass(java.lang.String className)
className
- class to return
public static java.lang.Object getClass(java.lang.String className, java.lang.Class caller)
public static java.io.File getFile(java.io.File path, java.lang.String filePath)
path
- parent pathfilePath
- file path
public static java.lang.String getPath(java.io.File path, java.lang.String filePath)
path
- parent pathfilePath
- file path
public static java.io.File prepareDirectory(java.io.File parent, java.lang.String directoryPath, java.lang.String parameter) throws org.apache.maven.plugin.MojoExecutionException
parent
- parent filedirectoryPath
- child directory pathparameter
- name of the parameter calling this method
org.apache.maven.plugin.MojoExecutionException
- if the directory is not a directorypublic static java.io.File prepareDirectory(java.io.File directory, java.lang.String parameter) throws org.apache.maven.plugin.MojoExecutionException
directory
- child directoryparameter
- name of the parameter calling this method
org.apache.maven.plugin.MojoExecutionException
- if the directory is not a directorypublic static java.io.File prepareFile(java.io.File parent, java.lang.String filePath, java.lang.String parameter) throws org.apache.maven.plugin.MojoExecutionException
parent
- parent filefilePath
- child file pathparameter
- name of the parameter calling this method
org.apache.maven.plugin.MojoExecutionException
- if the file is not a file
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |