return 0;\r
}\r
\r
-bool CKernel::AddTask(CMMPointer<ITask> t)\r
+bool CKernel::AddTask(const CMMPointer<ITask> &t)\r
{\r
if(!t->Start())return false;\r
\r
return true;\r
}\r
\r
-void CKernel::SuspendTask(CMMPointer<ITask> t)\r
+void CKernel::SuspendTask(const CMMPointer<ITask> &t)\r
{\r
//check that this task is in our list - we don't want to suspend a task that isn't running\r
if(std::find(taskList.begin(),taskList.end(),t)!=taskList.end())\r
}\r
}\r
\r
-void CKernel::ResumeTask(CMMPointer<ITask> t)\r
+void CKernel::ResumeTask(const CMMPointer<ITask> &t)\r
{\r
if(std::find(pausedTaskList.begin(),pausedTaskList.end(),t)!=pausedTaskList.end())\r
{\r
}\r
}\r
\r
-void CKernel::RemoveTask(CMMPointer<ITask> t)\r
+void CKernel::RemoveTask(const CMMPointer<ITask> &t)\r
{\r
if(std::find(taskList.begin(),taskList.end(),t)!=taskList.end())\r
{\r
\r
int Execute();\r
\r
- bool AddTask(CMMPointer<ITask> t);\r
- void SuspendTask(CMMPointer<ITask> t);\r
- void ResumeTask(CMMPointer<ITask> t);\r
- void RemoveTask(CMMPointer<ITask> t);\r
+ bool AddTask(const CMMPointer<ITask> &t);\r
+ void SuspendTask(const CMMPointer<ITask> &t);\r
+ void ResumeTask(const CMMPointer<ITask> &t);\r
+ void RemoveTask(const CMMPointer<ITask> &t);\r
void KillAllTasks();\r
\r
protected:\r
DestroyStandardSettings();\r
}\r
\r
-void CSettingsManager::RegisterVariable(std::string name, CMMPointer<BaseDator> var)\r
+void CSettingsManager::RegisterVariable(const std::string &name, const CMMPointer<BaseDator> &var)\r
{\r
settingMap[name]=var;\r
}\r
CSettingsManager();\r
virtual ~CSettingsManager();\r
\r
- void RegisterVariable(std::string name, CMMPointer<BaseDator> var);\r
+ void RegisterVariable(const std::string &name, const CMMPointer<BaseDator> &var);\r
void SetVariable(std::string &name, std::string &value, int bias=0);\r
\r
void CreateStandardSettings();\r