MCPcopy
hub / github.com/pallets/werkzeug / listvalues

Method listvalues

src/werkzeug/datastructures/structures.py:382–390  ·  view source on GitHub ↗

Return an iterator of all values associated with a key. Zipping :meth:`keys` and this is the same as calling :meth:`lists`: >>> d = MultiDict({"foo": [1, 2, 3]}) >>> zip(d.keys(), d.listvalues()) == d.lists() True

(self)

Source from the content-addressed store, hash-verified

380 yield values[0]
381
382 def listvalues(self) -> cabc.Iterable[list[V]]:
383 """Return an iterator of all values associated with a key. Zipping
384 :meth:`keys` and this is the same as calling :meth:`lists`:
385
386 >>> d = MultiDict({"foo": [1, 2, 3]})
387 >>> zip(d.keys(), d.listvalues()) == d.lists()
388 True
389 """
390 return super().values() # type: ignore[return-value]
391
392 def copy(self) -> te.Self:
393 """Return a shallow copy of this object."""

Callers 1

test_iter_interfacesMethod · 0.45

Calls 1

valuesMethod · 0.45

Tested by 1

test_iter_interfacesMethod · 0.36