Extra Class APIs#
The decree-tree.extras
package includes several helper classes
based on DecreeTree
.
AbstractDT#
To simplify abstract class creation, use
decree_tree.extras.AbstractDT
. See
Deconfliction for more details.
- class decree_tree.extras.AbstractDT(*, name=None, inherit=True, prog_is_name=False, version=None)#
Bases:
DecreeTree
A mixin for creating abstract classes, which attempts to avoid issues resulting from mixing abstract with manual inheritance.
Initialize the variables specific to the combined DecreeTree. This method exists to make its interface explicit, rather than relying on unspecified
**kwargs
.- Parameters:
name (
str
|None
) – the command name, if overriding it for the instanceinherit (
bool
) – whether parents are considered when invoking a DecreeTreeprog_is_name (
bool
) – whether to useself.name
as the program name in helpversion (
str
|None
) – version information; use--version
to show