code: def fold(self, predicate):
          
          childs = {x:y.fold(predicate) for (x,y) in self._attributes.items()
                    if isinstance(y, SerializableTypedAttributesHolder)}
          return predicate(self, childs)
docs: Takes a predicate and applies it to each node starting from the
          leaves and making the return value propagate.