Пример #1
0
 private void mergeEnvironment(JobSpecification js, Map env) {
   Iterator i = js.getEnvironmentVariableNames().iterator();
   while (i.hasNext()) {
     String envName = (String) i.next();
     env.put(envName, js.getEnvironmentVariable(envName));
   }
 }
Пример #2
0
 private boolean detectEnvironmentConflict(JobSpecification js, Map env) {
   Iterator i = js.getEnvironmentVariableNames().iterator();
   while (i.hasNext()) {
     String envName = (String) i.next();
     Object value = env.get(envName);
     if (value != null && !value.equals(js.getEnvironmentVariable(envName))) {
       return true;
     }
   }
   return false;
 }
Пример #3
0
 private String getJavaHome(Task task) {
   JobSpecification js = (JobSpecification) task.getSpecification();
   return js.getEnvironmentVariable("JAVA_HOME");
 }