Class Main
- java.lang.Object
-
- fr.ens.biologie.genomique.aozan.aozan3.Main
-
public class Main extends Object
This class define the main class.- Since:
- 3.0
- Author:
- Laurent Jourdren
-
-
Field Summary
Fields Modifier and Type Field Description static String
APPLICATION_CLASSPATH_JVM_ARG
static String
APPLICATION_MEMORY
static String
APPLICATION_PATH
static String
APPLICATION_SCRIPT
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Action
getAction()
Get the action.List<String>
getActionArgs()
Get the action arguments.String
getApplicationClassPath()
Get the application classpath.Path
getApplicationDirectory()
Get the application directory.int
getApplicationMemory()
Get the application memory requirement.String
getApplicationScriptPath()
Get the application script path.List<String>
getArgs()
Get command line arguments.Configuration
getConfiguration()
Get the the startup configuration.int
getErrorExitCode()
Get the exit code to use when an error occurs.static Main
getInstance()
Get the instance of the Main class.String
getJavaExecutablePath()
Get java executable path.List<String>
getJVMArgs()
Get JVM arguments.fr.ens.biologie.genomique.kenetre.log.GenericLogger
getLogger()
Get the logger.protected void
help(org.apache.commons.cli.Options options)
Show command line help.static void
main(String[] args)
Main method of the program.protected org.apache.commons.cli.Options
makeOptions()
Create options for command line
-
-
-
Field Detail
-
APPLICATION_CLASSPATH_JVM_ARG
public static final String APPLICATION_CLASSPATH_JVM_ARG
- See Also:
- Constant Field Values
-
APPLICATION_SCRIPT
public static final String APPLICATION_SCRIPT
- See Also:
- Constant Field Values
-
APPLICATION_PATH
public static final String APPLICATION_PATH
- See Also:
- Constant Field Values
-
APPLICATION_MEMORY
public static final String APPLICATION_MEMORY
- See Also:
- Constant Field Values
-
-
Method Detail
-
getInstance
public static Main getInstance()
Get the instance of the Main class.- Returns:
- a Main object
-
getConfiguration
public Configuration getConfiguration()
Get the the startup configuration.- Returns:
- the startup configuration
-
getLogger
public fr.ens.biologie.genomique.kenetre.log.GenericLogger getLogger()
Get the logger.- Returns:
- the logger
-
getJavaExecutablePath
public String getJavaExecutablePath()
Get java executable path.- Returns:
- the path to the java executable
-
getJVMArgs
public List<String> getJVMArgs()
Get JVM arguments.- Returns:
- the JVM arguments as an array
-
getApplicationClassPath
public String getApplicationClassPath()
Get the application classpath. The result of the method is based on the content of the dedicated JVM argument.- Returns:
- the JVM class as a String
-
getApplicationScriptPath
public String getApplicationScriptPath()
Get the application script path.- Returns:
- the application script path
-
getApplicationMemory
public int getApplicationMemory()
Get the application memory requirement.- Returns:
- the application memory requirement
-
getApplicationDirectory
public Path getApplicationDirectory()
Get the application directory.- Returns:
- the application directory
-
getAction
public Action getAction()
Get the action.- Returns:
- Returns the action
-
getActionArgs
public List<String> getActionArgs()
Get the action arguments.- Returns:
- Returns the actionArgs
-
getErrorExitCode
public int getErrorExitCode()
Get the exit code to use when an error occurs.- Returns:
- Returns the exit code to use when an error occurs
-
help
protected void help(org.apache.commons.cli.Options options)
Show command line help.- Parameters:
options
- Options of the software
-
makeOptions
protected org.apache.commons.cli.Options makeOptions()
Create options for command line- Returns:
- an Options object
-
main
public static void main(String[] args)
Main method of the program.- Parameters:
args
- command line arguments
-
-