def METHOD_NAME(self) -> None:
    """Clear the node list."""
    if self._nodes:
        self._nodes.clear()
        self._nodes_set.clear()
        self._nodes_by_id.clear()
        self._updates += 1