示例#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;
 }