|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.compomics.software.CommandLineUtils
public class CommandLineUtils
This class groups some convenience methods for the use of compomics tools in command line.
Field Summary | |
---|---|
static java.lang.String |
SEPARATOR
The command line argument separator. |
Constructor Summary | |
---|---|
CommandLineUtils()
|
Method Summary | |
---|---|
static java.lang.String |
concatenate(java.util.ArrayList<java.lang.String> args)
Returns the list of arguments as space separated string for the command line. |
static java.lang.String |
concatenate(java.lang.String[] args)
Returns the list of arguments as space separated string for the command line. |
static java.lang.String |
getCommandLineArgument(java.util.ArrayList<java.io.File> files)
Returns the list of file as argument for the command line. |
static java.lang.String |
getCommandLineArgument(java.io.File file)
Returns the file as argument for the command line. |
static java.util.ArrayList<java.io.File> |
getFiles(java.lang.String optionInput,
java.util.ArrayList<java.lang.String> fileExtentions)
Returns a list of files as imported from the command line option. |
static java.util.ArrayList<java.lang.String> |
splitInput(java.lang.String cliInput)
Returns a list of file names for inputs of comma separated files. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String SEPARATOR
Constructor Detail |
---|
public CommandLineUtils()
Method Detail |
---|
public static java.lang.String getCommandLineArgument(java.util.ArrayList<java.io.File> files)
files
- the files
public static java.lang.String concatenate(java.util.ArrayList<java.lang.String> args)
args
- the arguments
public static java.lang.String concatenate(java.lang.String[] args)
args
- the arguments
public static java.lang.String getCommandLineArgument(java.io.File file)
file
- the file
public static java.util.ArrayList<java.lang.String> splitInput(java.lang.String cliInput)
cliInput
- the CLI input
public static java.util.ArrayList<java.io.File> getFiles(java.lang.String optionInput, java.util.ArrayList<java.lang.String> fileExtentions) throws java.io.FileNotFoundException
optionInput
- the command line optionfileExtentions
- the file extensions to be considered
java.io.FileNotFoundException
- exception thrown whenever a file is not
found
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |