|
|
| __init__ (self, doc, registry, default=None, optional=False, multi=False, on_none=None) |
| | __deepcopy__ (self, memo) |
|
| __init__ (self, doc, typemap, default=None, optional=False, multi=False, deprecated=None) |
|
| __class_getitem__ (cls, tuple[type,...]|type|ForwardRef params) |
|
ConfigChoiceField | __get__ (self, None instance, Any owner=None, Any at=None, str label="default") |
|
ConfigInstanceDict | __get__ (self, Config instance, Any owner=None, Any at=None, str label="default") |
|
| __get__ (self, instance, owner=None, at=None, label="default") |
|
None | __set__ (self, Config instance, ConfigInstanceDict|None value, Any at=None, str label="assignment") |
| | rename (self, instance) |
| | validate (self, instance) |
| | toDict (self, instance) |
| | freeze (self, instance) |
| | save (self, outfile, instance) |
| | __deepcopy__ (self, memo) |
|
| __class_getitem__ (cls, tuple[type,...]|type|ForwardRef params) |
|
| __init__ (self, doc, dtype=None, default=None, check=None, optional=False, deprecated=None) |
|
Field[FieldTypeVar] | __get__ (self, None instance, Any owner=None, Any at=None, str label="default") |
|
FieldTypeVar | __get__ (self, Config instance, Any owner=None, Any at=None, str label="default") |
| | __get__ (self, instance, owner=None, at=None, label="default") |
| None | __set__ (self, Config instance, FieldTypeVar|None value, Any at=None, str label="assignment") |
| | __delete__ (self, instance, at=None, label="deletion") |
|
|
| instanceDictClass = ConfigInstanceDict |
|
dict | supportedTypes = {str, bool, float, int, complex} |
|
| _getOrMake (self, instance, label="default") |
| Any | _copy_storage (self, Config old, Config new) |
| | _collectImports (self, instance, imports) |
| | _compare (self, instance1, instance2, shortcut, rtol, atol, output) |
| | _setup (self, doc, dtype, default, check, optional, source, deprecated) |
| | _validateValue (self, value) |
| Mapping[str, Any] | _parseTypingArgs (tuple[type,...]|tuple[str,...] params, Mapping[str, Any] kwds) |
A configuration field whose options are defined in a `Registry`.
Parameters
----------
doc : `str`
A description of the field.
registry : `Registry`
The registry that contains this field.
default : `str`, optional
The default target key.
optional : `bool`, optional
When `False`, `lsst.pex.config.Config.validate` fails if the field's
value is `None`.
multi : `bool`, optional
If `True`, the field allows multiple selections. The default is
`False`.
on_none : `Callable`, optional
A callable that should be invoked when ``apply`` is called but the
selected name or names is `None`. Will be passed the field attribute
proxy (`RegistryInstanceDict`) and then all positional and keyword
arguments passed to ``apply``.
See Also
--------
ChoiceField
ConfigChoiceField
ConfigDictField
ConfigField
ConfigurableField
DictField
Field
ListField
RangeField