Odyssey::TaskManager Class Reference

#include <TaskManager.h>

Inheritance diagram for Odyssey::TaskManager:

Odyssey::Manager< TaskPtr > List of all members.

Public Types

typedef std::set< Task * > TaskSet

Public Member Functions

TaskWeakPtr createTask (const String &typeID, const String &name)
 Create a task with the given type id and with the given name.
TaskWeakPtr getTask (const String &name) const
 Returns the task with the given name.
TaskWeakPtr getTask (size_t index) const
 Returns the task at the given index.
void _notifyActive (Task *task, bool active)
 An engine internal function for notification that a Task's active status changed.
void update (size_t index)
 Updates the task at the given index.
void update (const String &name)
 Updates the task with the given name.
void updateActive ()
 Updates all active tasks.
void updateAll ()
 Updates all tasks, regardless of active status.

Static Public Member Functions

static TaskManager & getSingleton ()
 Returns the one and only instance.

Protected Member Functions

void onRemoving (TaskPtr ptr)

Detailed Description

This class manages the Tasks within the system. It provides named and indexed access to all of the tasks, as well as tracking their active status.


Member Typedef Documentation

typedef std::set<Task*> Odyssey::TaskManager::TaskSet
 


Member Function Documentation

void Odyssey::TaskManager::_notifyActive (  Task *  task,
bool  active
) 
 

An engine internal function for notification that a Task's active status changed.

TaskWeakPtr Odyssey::TaskManager::createTask (  const String &  typeID,
const String &  name
) 
 

Create a task with the given type id and with the given name.

This function uses the underlying dynamic class system to create a new Task. The task is added to the managed list of tasks, and becomes available for immediate use.

Parameters:
typeID the type ID of the new task to create
name the name of the new Task

static TaskManager& Odyssey::TaskManager::getSingleton (   )  [static]
 

Returns the one and only instance.

TaskWeakPtr Odyssey::TaskManager::getTask (  size_t  index  )  const
 

Returns the task at the given index.

TaskWeakPtr Odyssey::TaskManager::getTask (  const String &  name  )  const
 

Returns the task with the given name.

void Odyssey::TaskManager::onRemoving (  TaskPtr  ptr  )  [protected]
 

void Odyssey::TaskManager::update (  const String &  name  ) 
 

Updates the task with the given name.

void Odyssey::TaskManager::update (  size_t  index  ) 
 

Updates the task at the given index.

void Odyssey::TaskManager::updateActive (   ) 
 

Updates all active tasks.

void Odyssey::TaskManager::updateAll (   ) 
 

Updates all tasks, regardless of active status.


The documentation for this class was generated from the following file:
Generated on Sun Jan 7 01:18:53 2007 for Odyssey Meta-Engine by  doxygen 1.4.6-NO