parameters: (self, funcOrTask, name = None, sort = None, extraArgs = None,
              priority = None, uponDeath = None, appendTask = False,
              taskChain = None, owner = None, delay = None)
return_statement: return task
docstring: Add a new task to the taskMgr.  The task will begin executing
          immediately, or next frame if its sort value has already
          passed this frame.
  
          Parameters:
              funcOrTask: either an existing Task object (not already
                  added to the task manager), or a callable function
                  object. If this is a function, a new Task object will be
                  created and returned. You may also pass in a coroutine
                  object.
  
              name (str): the name to assign to the Task.  Required,
                  unless you are passing in a Task object that already has
                  a name.
  
              extraArgs (list): the list of arguments to pass to the task
                  function.  If this is omitted, the list is just the task
                  object itself.
  
              appendTask (bool): If this is true, then the task object
                  itself will be appended to the end of the extraArgs list
                  before calling the function.
  
              sort (int): the sort value to assign the task.  The default
                  sort is 0.  Within a particular task chain, it is
                  guaranteed that the tasks with a lower sort value will
                  all run before tasks with a higher sort value run.
  
              priority (int): the priority at which to run the task.  The
                  default priority is 0.  Higher priority tasks are run
                  sooner, and/or more often.  For historical purposes, if
                  you specify a priority without also specifying a sort,
                  the priority value is understood to actually be a sort
                  value. (Previously, there was no priority value, only a
                  sort value, and it was called "priority".)
  
              uponDeath (bool): a function to call when the task
                  terminates, either because it has run to completion, or
                  because it has been explicitly removed.
  
              taskChain (str): the name of the task chain to assign the
                  task to.
  
              owner: an optional Python object that is declared as the
                  "owner" of this task for maintenance purposes.  The
                  owner must have two methods:
                  ``owner._addTask(self, task)``, which is called when the
                  task begins, and ``owner._clearTask(self, task)``, which
                  is called when the task terminates.  This is all the
                  ownermeans.
  
              delay: an optional amount of seconds to wait before starting
                  the task (equivalent to doMethodLater).
  
          Returns:
              The new Task object that has been added, or the original
              Task object that was passed in.
docstring_summary: Add a new task to the taskMgr.  The task will begin executing
          immediately, or next frame if its sort value has already
          passed this frame.
docstring_tokens: Add a new task to the taskMgr . The task will begin executing immediately or next frame if its sort value has already passed this frame .
function: def add(self, funcOrTask, name = None, sort = None, extraArgs = None,
              priority = None, uponDeath = None, appendTask = False,
              taskChain = None, owner = None, delay = None):
          """
          Add a new task to the taskMgr.  The task will begin executing
          immediately, or next frame if its sort value has already
          passed this frame.
  
          Parameters:
              funcOrTask: either an existing Task object (not already
                  added to the task manager), or a callable function
                  object. If this is a function, a new Task object will be
                  created and returned. You may also pass in a coroutine
                  object.
  
              name (str): the name to assign to the Task.  Required,
                  unless you are passing in a Task object that already has
                  a name.
  
              extraArgs (list): the list of arguments to pass to the task
                  function.  If this is omitted, the list is just the task
                  object itself.
  
              appendTask (bool): If this is true, then the task object
                  itself will be appended to the end of the extraArgs list
                  before calling the function.
  
              sort (int): the sort value to assign the task.  The default
                  sort is 0.  Within a particular task chain, it is
                  guaranteed that the tasks with a lower sort value will
                  all run before tasks with a higher sort value run.
  
              priority (int): the priority at which to run the task.  The
                  default priority is 0.  Higher priority tasks are run
                  sooner, and/or more often.  For historical purposes, if
                  you specify a priority without also specifying a sort,
                  the priority value is understood to actually be a sort
                  value. (Previously, there was no priority value, only a
                  sort value, and it was called "priority".)
  
              uponDeath (bool): a function to call when the task
                  terminates, either because it has run to completion, or
                  because it has been explicitly removed.
  
              taskChain (str): the name of the task chain to assign the
                  task to.
  
              owner: an optional Python object that is declared as the
                  "owner" of this task for maintenance purposes.  The
                  owner must have two methods:
                  ``owner._addTask(self, task)``, which is called when the
                  task begins, and ``owner._clearTask(self, task)``, which
                  is called when the task terminates.  This is all the
                  ownermeans.
  
              delay: an optional amount of seconds to wait before starting
                  the task (equivalent to doMethodLater).
  
          Returns:
              The new Task object that has been added, or the original
              Task object that was passed in.
          """
  
          task = self.__setupTask(funcOrTask, name, priority, sort, extraArgs, taskChain, appendTask, owner, uponDeath)
          if delay is not None:
              task.setDelay(delay)
          self.mgr.add(task)
          return task
function_tokens: def add ( self , funcOrTask , name = None , sort = None , extraArgs = None , priority = None , uponDeath = None , appendTask = False , taskChain = None , owner = None , delay = None ) : task = self . __setupTask ( funcOrTask , name , priority , sort , extraArgs , taskChain , appendTask , owner , uponDeath ) if delay is not None : task . setDelay ( delay ) self . mgr . add ( task ) return task