private static Properties searchPropertiesForEnvironment(
     String envName, EnvParamDescriptor descriptor) {
   Properties properties = new Properties();
   try {
     List<Environment> environments = descriptor.getEnvironments();
     for (Environment environment : environments) {
       if (environment.getName().equals(envName)) {
         properties.load(new StringReader(environment.getProperties()));
         break;
       }
     }
   } catch (IOException e) {
     // never happened
   }
   return properties;
 }
Exemplo n.º 2
0
 public boolean supportsEnvironment(Environment environment) {
   return supportsValueInIncludeExcludeMap(pluginEnvs, environment.getName());
 }