config.utils¶
杂项实用程序
在 0.2.0 版本加入.
Attributes¶
用于填充默认值的特殊值 |
Classes¶
存储冻结的参数的容器 |
|
间接持有对象引用的容器 |
|
用于填充默认值的特殊值 |
Functions¶
|
单例模式类装饰器 |
Module Contents¶
- class FrozenArguments(args: collections.abc.Sequence[Any] | None = None, kwargs: collections.abc.Mapping[str, Any] | None = None)¶
存储冻结的参数的容器
在 0.3.0 版本加入.
- 参数:
args (Sequence[Any]) -- 位置参数
kwargs (Mapping[str, Any]) -- 关键字参数
- __iter__() collections.abc.Iterator[tuple[Any, Ellipsis] | collections.OrderedDict[str, Any]]¶
- __or__(other: tuple[collections.abc.Sequence[Any], collections.abc.Mapping[str, Any]] | Self) Self | types.NotImplementedType¶
- _args = ()¶
- property kwargs: collections.OrderedDict[str, Any]¶
关键字参数
- 返回:
关键字参数
- 返回类型:
OrderedDict[str, Any]
- class Ref(value: T)¶
间接持有对象引用的容器
在 0.3.0 版本发生变更: 重命名
CellType为Ref重命名字段
cell_contents为value- 参数:
value (T) -- 引用对象
- __slots__ = ('value',)¶
- value¶
- singleton(target_cls: singleton.C, /) singleton.C¶
单例模式类装饰器
- 参数:
target_cls (C) -- 目标类
- 返回:
装饰后的类
- 返回类型:
C
- Unset¶
用于填充默认值的特殊值