Skip to main content

confrozenset

A wrapper around typing.FrozenSet that allows for additional constraints.

def confrozenset(
item_type: type[HashableItemType],
min_length: int | None = None,
max_length: int | None = None
) - > type[frozenset[HashableItemType]]

A wrapper around typing.FrozenSet that allows for additional constraints.

Parameters

NameTypeDescription
item_typetype[HashableItemType]The type of the items in the frozenset.
min_length`intNone` = None
max_length`intNone` = None

Returns

TypeDescription
type[frozenset[HashableItemType]]The wrapped frozenset type.