Collections.UserDict

#python #programming #language #datastructure #datamodel

  • Has the method __update__ and __get__ already implemented
  • Avoid recursion on method __setitem__ using a variable data to store the dictionary itself.
  • key in data is the implementation of the method __contains__

References

Ramalho, 2022, p97-100

Links to this page
#python #programming #language #datastructure #datamodel