ProcessorFactory

ProcessorFactory

class ProcessorFactory[source]

Bases: Generic[configpile.processor._Config]

Describes a processor in construction

This factory is passed to the different arguments present in the configuration.

Attributes

Note: attributes inherited from parent classes are not shown here, if any

params_by_name

List of parameters indexed by their field name

argument_parser

Argument parser to update, used to display help and for the Sphinx documentation

ap_commands

Argument parser group for commands

ap_required

Argument parser group for required parameters

ap_optional

Argument parser group for optional parameters

env_handlers

Handlers for environment variables

ini_section_strict

List of INI sections with their corresponding strictness

ini_handlers

List of handlers for key/value pairs present in INI files

cl_flag_handlers

List of command line flag handlers

cl_positionals

List of positional arguments

validators

Methods

make

Constructs an empty processor factory

List of members of ProcessorFactory

params_by_name: Dict[str, configpile.arg.Param[Any]]

List of parameters indexed by their field name

argument_parser: argparse.ArgumentParser

Argument parser to update, used to display help and for the Sphinx documentation

ap_commands: argparse._ArgumentGroup

Argument parser group for commands

ap_required: argparse._ArgumentGroup

Argument parser group for required parameters

ap_optional: argparse._ArgumentGroup

Argument parser group for optional parameters

env_handlers: Dict[str, configpile.handlers.KVHandler]

Handlers for environment variables

ini_section_strict: Dict[str, bool]

List of INI sections with their corresponding strictness

ini_handlers: Dict[str, configpile.handlers.KVHandler]

List of handlers for key/value pairs present in INI files

cl_flag_handlers: Dict[str, configpile.handlers.CLHandler]

List of command line flag handlers

cl_positionals: List[configpile.arg.Param[Any]]

List of positional arguments

validators: List[Callable[[configpile.processor._Config], Optional[configpile.userr.Err]]]
static make(config_type)[source]

Constructs an empty processor factory

Parameters

config_type (Type[TypeVar(_Config, bound= Config)]) – Configuration to process

Return type

ProcessorFactory[TypeVar(_Config, bound= Config)]

Returns

A processor factory

__init__(params_by_name, argument_parser, ap_commands, ap_required, ap_optional, env_handlers, ini_section_strict, ini_handlers, cl_flag_handlers, cl_positionals, validators)
static __new__(cls, *args, **kwds)