def METHOD_NAME(self, path):
    # type: (QPainterPath) -> None
    """Set the items `path` (:class:`QPainterPath`).
    """
    if self.__path != path:
        self.prepareGeometryChange()
        # Need to store a copy of object so the shape can't be mutated
        # without properly updating the geometry.
        self.__path = QPainterPath(path)
        self.__boundingRect = None
        self.update()