diplomat.processing.type_casters.StrictCallable
- class diplomat.processing.type_casters.StrictCallable(*args, **kwds)[source]
Bases:
ConvertibleTypeCasterA type caster that can be used to run strict argument name and type checking on type casting functions. Useful for API conformance checks.
- __init__(*, _return: TypeCaster = None, _kwargs: bool = False, **kwargs: TypeCaster)[source]
Methods
__init__(*[, _return, _kwargs])Convert this type to a CLI-Friendly format for display on the command line as a metavar.
Abstract method: Convert this typecaster instance to a regular type hint.
- to_metavar() str
Convert this type to a CLI-Friendly format for display on the command line as a metavar.
- Returns
A string, the CLI Friendly format for this type.