larry._utils._auto_parse_base_class¶
Module Contents¶
Classes¶
Helper class that provides a standard way to create an ABC using |
- class larry._utils._auto_parse_base_class.AutoParseBase¶
Bases:
abc.ABCHelper class that provides a standard way to create an ABC using inheritance.
- property _init_params¶
- property _call_params¶
- property _parse_params¶
- property _collected_params¶
- __call__()¶
- __init_kwargs__()¶
- _inspect(func)¶
- _collect_literal_kwargs(kwargs_val)¶
- __hide__(key)¶
- __collect__(key, val)¶
- __parse__(kwargs: dict, ignore: list = ['self'], private: list = ['ignore', 'private', 'public'], public: list = [], kwargs_key: str = 'kwargs')¶
Pass locals() or some other collection of kwargs to kwargs to save them as attributes of the subclass.
- kwargs
typically locals() type: dict
- ignore
type: list default: [“self”]
- private
type: list default: [“ignore”, “private”, “public”]
- public
type: list default: []
- kwargs_key
type: str default: “kwargs”
assumes all are public unless denoted in private
If a public list is provided, all kwargs are shifted to private unless denoted in public.