Salome HOME
Add the preprocess feature to SALOME_Launcher.
[modules/kernel.git] / src / Launcher / Launcher_Job.cxx
index e046fd8cfc14d88b8f5ed7a3fed573a1873bdb47..e3a2fc615c40a67d6370c03adbd64ae4b7bd9eee 100644 (file)
@@ -40,6 +40,7 @@ Launcher::Job::Job()
   _job_file = "";
   _job_file_name = "";
   _job_file_name_complete = "";
+  _pre_command = "";
   _work_directory = "";
   _local_directory = "";
   _result_directory = "";
@@ -442,6 +443,18 @@ Launcher::Job::getReference() const
   return _reference;
 }
 
+void
+Launcher::Job::setPreCommand(const std::string & preCommand)
+{
+  _pre_command = preCommand;
+}
+
+std::string
+Launcher::Job::getPreCommand() const
+{
+  return _pre_command;
+}
+
 void
 Launcher::Job::checkMaximumDuration(const std::string & maximum_duration)
 {
@@ -604,6 +617,7 @@ Launcher::Job::common_job_params()
     }
   }
   params[Batch::WORKDIR] = _work_directory;
+  params[Batch::PREPROCESS] = _pre_command;
 
   // Parameters for COORM
   params[Batch::LAUNCHER_FILE] = _launcher_file;