Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members

TaskManager Class Reference

Class managing a Task. More...

#include <TaskManager.h>

List of all members.

Public Member Functions

int getInfoShmid ()
bool isTaskRunning ()
 Check if a task is currently running.
void setTaskRunning (bool isRunning)
 Task running setter.
int getReturnValue ()
 Return value of the executed task.
bool registerTask (Task *aTask)
 Register a task to execute.
bool executeCurrentTask ()
 Execute the task that was already registered.
bool createCurrentTaskSummary ()
 Create a txt file, which describes the execution process of the task (error or not, task name, host name, exec time).
bool archiveCurrentTask ()
 Archive (tar.gz) the task that was already registered.
bool copyCurrentTaskArchive ()
 Copy archive (tar.gz) on the storage file system.
bool deleteCurrentTaskArchive ()
 Delete archive (tar.gz) on the local file system.
Task * getTask ()
char * getTaskName ()

Static Public Member Functions

static TaskManagerInstance (std::string aIpAddr, std::string aAgentPath, std::string aMountPoint)
 Singleton constructor.

Static Public Attributes

static const std::string kLOGS_DIR


Detailed Description

Class managing a Task.

Author:
Vincent JOUSSE
Version:
1.0


Member Function Documentation

bool TaskManager::archiveCurrentTask  ) 
 

Archive (tar.gz) the task that was already registered.

Returns:
Success or not

bool TaskManager::copyCurrentTaskArchive  ) 
 

Copy archive (tar.gz) on the storage file system.

Returns:
Success or not

bool TaskManager::createCurrentTaskSummary  ) 
 

Create a txt file, which describes the execution process of the task (error or not, task name, host name, exec time).

Returns:
Success or not

bool TaskManager::deleteCurrentTaskArchive  ) 
 

Delete archive (tar.gz) on the local file system.

Returns:
Success or not

bool TaskManager::executeCurrentTask  ) 
 

Execute the task that was already registered.

Returns:
Success or not

Task* TaskManager::getTask  ) 
 

Return current running task (do not use from other process).

static TaskManager* TaskManager::Instance std::string  aIpAddr,
std::string  aAgentPath,
std::string  aMountPoint
[static]
 

Singleton constructor.

Check unicity of singleton, based on pinstance value.

bool TaskManager::registerTask Task *  aTask  ) 
 

Register a task to execute.

Parameters:
aTask The descriptor of the task


Member Data Documentation

const std::string TaskManager::kLOGS_DIR [static]
 

Directory name inside the Task path were results are stored


The documentation for this class was generated from the following file:
Generated on Fri May 19 23:15:28 2006 for k10-agent by  doxygen 1.4.4