ArgumentParser Class Reference
+ Inheritance diagram for ArgumentParser:

Public Member Functions

def __init__ (self, prog=None, usage=None, description=None, epilog=None, version=None, parents=None, formatter_class=BriefHelpFormatter, prefix_chars='-', fromfile_prefix_chars=None, argument_default=None, conflict_handler='error', add_help=True)
 
def format_help (self)
 
def add_argument_group (self, *args, **kwargs)
 
def add_output_argument_group (self, *args, **kwargs)
 
def add_argument (self, *args, **kwargs)
 
def parse_args (self, args=None, namespace=None)
 
def generate_proxy_cls (self)
 construct class from a dict containing object definition (name, attributes) More...
 
def print_single_help (self, values)
 
def print_doxygen_help (self, file=None)
 

Public Attributes

 user_actions
 
 action_extras
 
 doxygen_description_width
 
 epilog
 

Detailed Description

 Custom OPALS style ArgumentParser class to enable similar parameter style with C++ version

Member Function Documentation

◆ add_argument()

def add_argument (   self,
args,
**  kwargs 
)
     accept more items in add_arguments and remove before fall-back to superclass' implementation

     additional keyword:
     - remarks : mandatory, deprecated, Estimable()
     - brief and description : short and long help text

References ArgumentGroup.action_extras, ArgumentParser.action_extras, ArgumentParser.epilog, python.tools.opalsargparse.preprocess_kwargs(), ArgumentGroup.user_actions, and ArgumentParser.user_actions.

◆ generate_proxy_cls()

def generate_proxy_cls (   self)

construct class from a dict containing object definition (name, attributes)

◆ print_doxygen_help()

def print_doxygen_help (   self,
  file = None 
)
             generate doxygen documentation for each action
         argument group unique identifier
         recursively generates doxygen documentation for each argument group

References ArgumentParser._group_ctr, ArgumentParser.doxygen_description_width, ArgumentGroup.user_actions, and ArgumentParser.user_actions.

◆ print_single_help()

def print_single_help (   self,
  values 
)
     print detailed help information for a single parameter option