RegistryField#

class lsst.pex.config.RegistryField(doc, registry, default=None, optional=False, multi=False, on_none=None)#

Bases: ConfigChoiceField

A configuration field whose options are defined in a Registry.

Parameters#

docstr

A description of the field.

registryRegistry

The registry that contains this field.

defaultstr, optional

The default target key.

optionalbool, optional

When False, lsst.pex.config.Config.validate fails if the field’s value is None.

multibool, optional

If True, the field allows multiple selections. The default is False.

on_noneCallable, 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