MCPcopy Create free account
hub / github.com/bslatkin/effectivepython / _traverse_dict

Method _traverse_dict

example_code/item_054.py:55–59  ·  view source on GitHub ↗
(self, instance_dict)

Source from the content-addressed store, hash-verified

53 return self._traverse_dict(self.__dict__)
54
55 def _traverse_dict(self, instance_dict):
56 output = {}
57 for key, value in instance_dict.items():
58 output[key] = self._traverse(key, value)
59 return output
60
61 def _traverse(self, key, value):
62 if isinstance(value, ToDictMixin):

Callers 2

to_dictMethod · 0.95
_traverseMethod · 0.95

Calls 1

_traverseMethod · 0.95

Tested by

no test coverage detected