Data Integrator (Python API)
|
Argument parser for Dintegrator shell scripts. More...
Public Member Functions | |
def | __init__ (s, version, **kw) |
Ctor. More... | |
def | GetVersion (s) |
Get the program version string. More... | |
def | AddHeaderArg (s) |
Add argument for optional header availability. More... | |
def | AddColumnArg (s, help="", required=True) |
Add argument for a column specifier. More... | |
def | AddNoDataSpecifier (s) |
Adds 'no data in cell' specifier option. More... | |
def | AddChooseDataVersionArg (s) |
Adds the data version setting parameter. More... | |
def | AddPositionalTSVFileArg (s) |
Adds the frequently used input file name argument. More... | |
def | AddPermissiveness (s, default=PERMISSIVENESS_ECHO) |
Add argument on how to behave if the input file is inconsistent. More... | |
Static Public Attributes | |
ap | |
Argument parser for Dintegrator shell scripts.
This class attempts to unify the interface between different scripts. If you find a parameter that is not specific to a certain task, feel free to add it to this base class. Candidates to be added to this class: - --in Input format for gene ID conversion. - --out Output format for gene ID conversion. This class registers a special action which allows to print a list of choices in a help-like manner. The new action type is called @c choices and needs the @c choices argument set to a @c list of @c strings that will be printed when invoked. After that, the program exits gracefully without any more parsing and argument checking.
def cls.ArgumentParserBase.CArgumentParserBase.__init__ | ( | s, | |
version, | |||
** | kw | ||
) |
Ctor.
Already implements --version. @param version Version string of the command line tool. Format: major.minor
def cls.ArgumentParserBase.CArgumentParserBase.AddChooseDataVersionArg | ( | s | ) |
Adds the data version setting parameter.
def cls.ArgumentParserBase.CArgumentParserBase.AddColumnArg | ( | s, | |
help = "" , |
|||
required = True |
|||
) |
Add argument for a column specifier.
Stores integer result in 'column'. @param help Help text associated with the column optional argument. @param required True for positional, False for optional argument.
def cls.ArgumentParserBase.CArgumentParserBase.AddHeaderArg | ( | s | ) |
Add argument for optional header availability.
Stores boolean result in 'haveHeader'.
def cls.ArgumentParserBase.CArgumentParserBase.AddNoDataSpecifier | ( | s | ) |
Adds 'no data in cell' specifier option.
def cls.ArgumentParserBase.CArgumentParserBase.AddPermissiveness | ( | s, | |
default = PERMISSIVENESS_ECHO |
|||
) |
Add argument on how to behave if the input file is inconsistent.
Stores a string result in 'permissiveness'.
[optional] | Default permissiveness model. |
def cls.ArgumentParserBase.CArgumentParserBase.AddPositionalTSVFileArg | ( | s | ) |
Adds the frequently used input file name argument.
def cls.ArgumentParserBase.CArgumentParserBase.GetVersion | ( | s | ) |
Get the program version string.
|
static |