atom.typing_utils module

class atom.typing_utils.ChangeDict[source]

Bases: dict

count: int
index: int
item: Any
key: Any
name: str
newitem: Any
object: Atom
olditem: Any
oldvalue: Any
operation: Literal['reverse'] | Literal['__delitem__'] | Literal['__iadd__'] | Literal['__imul__'] | Literal['__setitem__'] | Literal['append'] | Literal['extend'] | Literal['insert'] | Literal['pop'] | Literal['remove'] | Literal['sort']
reverse: bool
type: Literal['create'] | Literal['update'] | Literal['delete'] | Literal['event'] | Literal['property'] | Literal['container']
value: Any
atom.typing_utils.extract_types(kind: type | TypeVar | UnionType | GenericAlias | Tuple[type | TypeVar | UnionType | GenericAlias, ...]) Tuple[type, ...][source]

Extract a tuple of types from a type-like object or tuple.

atom.typing_utils.is_optional(kinds: Tuple[type, ...]) Tuple[bool, Tuple[type, ...]][source]

Determine if a tuple of types contains NoneType.