Skip to content

module internal.types.collections.dict

Source: stdlib/internal/types/collections/dict.codon


Dict[K,V]

Fields

K: type

V: type

Magic methods

__init__(self)

__init__(self, g: Generator[Tuple[K, V]])

__init__(self, other: Dict[K, V])

__getitem__(self, key: K)

__setitem__(self, key: K, val: V)

__delitem__(self, key: K)

__contains__(self, key: K)

__eq__(self, other: Dict[K, V])

__ne__(self, other: Dict[K, V])

__iter__(self)

__len__(self)

__or__(self, other)

__ior__(self, other)

__copy__(self)

__deepcopy__(self)

__repr__(self)

__dict_do_op_throws__(self, key: K, other: Z, op: F, F: type, Z: type)

__dict_do_op__(self, key: K, other: Z, dflt: V, op: F, F: type, Z: type)

Methods

resize(self, new_n_buckets: int)

get(self, key: K, s: V)

setdefault(self, key: K, val: V)

increment(self, key: K, by: T = 1, T: type)

update(self, other)

update(self, other: Dict[K, V])

pop(self, key: K)

popitem(self)

clear(self)

items(self)

keys(self)

values(self)

copy(self)

fromkeys(ks: Generator[K], v: V, K: type, V: type)


dict = Dict