harp.utils.collections¶
- class MultiChainMap[source]¶
Bases:
ChainMap
Implements the logic of chainmap, but for multidicts. It also allows to unset values on some key, this will be used for headers, cookies, query string … to allow the user to rewrite requests/responses in a memory efficient way.
The current implementation is neither complete, nor optimized.
TODO: find a better way for __iter__
Initialize a ChainMap by setting maps to the given mappings. If no mappings are provided, a single empty dictionary is used.