public String getConfigFile(ContextConfigurator configurator) {
return configFile == null ? (getRootPath(configurator) + "/" + configurator.get(CONFIG_FILE)) : configFile;
}
public ContextConfigurator update(ContextConfigurator defaults) {
ContextConfigurator result = defaults;
result = result.withParameter(LOG_LEVEL, verboseLogging ? "verbose" : "normal");
if (configFile != null)
result = result.withParameter(CONFIG_FILE, configFile);
if (port != null)
result = result.withPort(port);
if (rootPath != null)
result = result.withRootPath(rootPath);
if (rootDirectory != null)
result = result.withRootDirectoryName(rootDirectory);
if (output != null)
result = result.withParameter(OUTPUT, output);
if (logDirectory != null)
result = result.withParameter(LOG_DIRECTORY, logDirectory);
if (daysTillVersionsExpire != null)
result = result.withParameter(VERSIONS_CONTROLLER_DAYS, daysTillVersionsExpire.toString());
if (omitUpdate)
result = result.withParameter(OMITTING_UPDATES, "true");
if (installOnly)
result = result.withParameter(INSTALL_ONLY, "true");
if (command != null)
result = result.withParameter(COMMAND, command);
if (credentials != null)
result = result.withParameter(CREDENTIALS, credentials);
return result;
}