parameters: (self)
docstring: This method should be called when intending to destroy the Actor, and
          cleans up any additional resources stored on the Actor class before
          removing the underlying node using `removeNode()`.
  
          Note that `removeNode()` itself is not sufficient to destroy actors,
          which is why this method exists.
docstring_summary: This method should be called when intending to destroy the Actor, and
          cleans up any additional resources stored on the Actor class before
          removing the underlying node using `removeNode()`.
docstring_tokens: This method should be called when intending to destroy the Actor and cleans up any additional resources stored on the Actor class before removing the underlying node using removeNode () .
function: def cleanup(self):
          """
          This method should be called when intending to destroy the Actor, and
          cleans up any additional resources stored on the Actor class before
          removing the underlying node using `removeNode()`.
  
          Note that `removeNode()` itself is not sufficient to destroy actors,
          which is why this method exists.
          """
          self.stop(None)
          self.clearPythonData()
          self.flush()
          if self.__geomNode:
              self.__geomNode.removeNode()
              self.__geomNode = None
          if not self.isEmpty():
              self.removeNode()
function_tokens: def cleanup ( self ) : self . stop ( None ) self . clearPythonData ( ) self . flush ( ) if self . __geomNode : self . __geomNode . removeNode ( ) self . __geomNode = None if not self . isEmpty ( ) : self . removeNode ( )