rename method

This commit is contained in:
Brian Baldino 2020-09-23 08:50:41 -07:00
parent af6b7b8a6a
commit 3be726d918
2 changed files with 5 additions and 5 deletions

View File

@ -1091,12 +1091,12 @@ public final class ConfigFactory {
}
/**
* Parse only any application overrides (those specified by config.{resource,file,url}), returning
* Parse only any application replacement (specified by one of config.{resource,file,url}), returning
* an empty Config if no overrides were set.
* @param parseOptions parse options
* @return the parsed configuration
*/
public static Config parseApplicationOverride(ConfigParseOptions parseOptions) {
public static Config parseApplicationReplacement(ConfigParseOptions parseOptions) {
ClassLoader loader = parseOptions.getClassLoader();
if (loader == null)

View File

@ -8,11 +8,11 @@ package com.typesafe.config;
public class DefaultConfigLoadingStrategy implements ConfigLoadingStrategy {
@Override
public Config parseApplicationConfig(ConfigParseOptions parseOptions) {
Config overrideConfig = ConfigFactory.parseApplicationOverride(parseOptions);
if (overrideConfig.isEmpty()) {
Config applicationReplacement = ConfigFactory.parseApplicationReplacement(parseOptions);
if (applicationReplacement.isEmpty()) {
return ConfigFactory.parseResourcesAnySyntax("application", parseOptions);
} else {
return overrideConfig;
return applicationReplacement;
}
}
}