Skip to content

BunchBunch, OrderedBunch, DefaultBunch, ProxyBunch #61

@dsc

Description

@dsc

I've been a bad maintainer, bc I have code for...

  • BunchBunch — essentially the same as calling bunchify() in the constructor, creating recursive bunches out of sub-dictionaries ... but as a feature of a subclass.
  • OrderedBunch — ensures keys have stable iteration order.
  • DefaultBunch — requests for missing keys return a given value / consult a function.
  • ProxyBunch — multiple bunches form a "cascade" of lookups where the first hit is returned.
  • BorgBunch — many Bunch, one dict. I rarely find a use for this, but it's always a a cool and easy addition.

In addition, each supports multiple inheritance when reasonable.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions