Author: remi
Date: 2009-04-18 16:09:16 +0200 (Sat, 18 Apr 2009)
New Revision: 4559

Modified:
   softwares_suite_v3/kysoh/tuxware/server/trunk/util/scheduler/Scheduler.py
Log:
* added a missing method ...

Modified: 
softwares_suite_v3/kysoh/tuxware/server/trunk/util/scheduler/Scheduler.py
===================================================================
--- softwares_suite_v3/kysoh/tuxware/server/trunk/util/scheduler/Scheduler.py   
2009-04-18 12:24:11 UTC (rev 4558)
+++ softwares_suite_v3/kysoh/tuxware/server/trunk/util/scheduler/Scheduler.py   
2009-04-18 14:09:16 UTC (rev 4559)
@@ -292,6 +292,23 @@
         return result
 
     # 
--------------------------------------------------------------------------
+    # Get a task by its name.
+    # 
--------------------------------------------------------------------------
+    def getTaskByName(self, taskName):
+        """Get a task by its name.
+        @param taskName: Task name.
+        @return: The task object.
+        """
+        task = None
+        self.__tasksToExecuteStackMutex.acquire()
+        for taskInfo in self.__tasksToExecuteStack:
+            if taskInfo[TASK_NAME] == taskName:
+                task = taskInfo[TASK_OBJECT]
+                break
+        self.__tasksToExecuteStackMutex.release()
+        return task
+
+    # 
--------------------------------------------------------------------------
     # Remove a task from the scheduler by its identifier.
     # 
--------------------------------------------------------------------------
     def removeTaskById(self, taskId):


------------------------------------------------------------------------------
Stay on top of everything new and different, both inside and 
around Java (TM) technology - register by April 22, and save
$200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco.
300 plus technical and hands-on sessions. Register today. 
Use priority code J9JMT32. http://p.sf.net/sfu/p
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn

Reply via email to