JAL-2890 made the submitted job a class value and added getter for it
authorkjvdheide <kjvanderheide@dundee.ac.uk>
Thu, 1 Feb 2018 17:06:03 +0000 (17:06 +0000)
committerkjvdheide <kjvanderheide@dundee.ac.uk>
Thu, 1 Feb 2018 17:06:03 +0000 (17:06 +0000)
src/jalview/ext/cipres/TreeJob.java

index 6ad8033..5977a67 100644 (file)
@@ -18,6 +18,8 @@ public class TreeJob
 
   private final CiApplication app = CiApplication.getInstance();
 
+  private CiJob submittedJob;
+
   private String tool;
 
   private Map<String, Collection<String>> vParams = new HashMap<>();
@@ -178,7 +180,7 @@ public class TreeJob
    */
   public CiJob submitJob(String toolName)
   {
-    CiJob submittedJob = null;
+
     if (!paramsValidated)
     {
       // validate before running some expensive job first.
@@ -196,6 +198,7 @@ public class TreeJob
       {
         submittedJob = cipresClient
                 .submitJob(toolName, vParams, inputParams, metadata);
+
       } catch (CiCipresException ce)
       {
         ErrorData ed = ce.getErrorData();
@@ -216,5 +219,9 @@ public class TreeJob
     return submittedJob;
   }
 
+  public CiJob getSubmittedJob()
+  {
+    return submittedJob;
+  }
 
 }