ConfigFactory¶
- class scooch.ConfigFactory(interactive)¶
A class for making configurations for class hierarchies out of the box.
Constructor
- Args:
interactive: bool - Whether to prompt user for input when constructing a configuration.
- create_config(cls, level=0)¶
Generates a configuration for this configurable, with all default values filled out, comments in place, and sub-configurables selected by the user (or placeholders are inserted).
- Args:
cls: Configurable - A Configurable class to construct a configuration for.
level: int - How many layers deep in a configuration heirarchy we are. This can help with printing prompts in interactive mode.
- Returns:
Config - The constructed configurable with placeholders where no defaults exist.