use of com.tvd12.ezyfoxserver.setting.EzySettings in project ezyfox-server by youngmonkeys.
the class EzySimpleSettingsReader method readSettings.
protected EzySettings readSettings() {
logger.info("read setting file: {}", getSettingsFilePath());
EzyXmlReader xmlReader = newXmlReader();
EzySimpleSettings settings = readSettingsFile(xmlReader);
EzySimpleZoneFilesSetting zoneFiles = settings.getZoneFiles();
zoneFiles.forEach(zf -> {
if (!zf.isActive()) {
return;
}
EzySimpleZoneSetting zoneSetting = readZoneConfigFile(xmlReader, zf.getConfigFile());
postReadZoneSettings(zoneSetting);
zoneSetting.setName(zf.getName());
zoneSetting.setConfigFile(zf.getConfigFile());
zoneSetting.init();
settings.addZone(zoneSetting);
});
if (settingsDecorator != null) {
settingsDecorator.decorate(homePath, settings);
}
return settings;
}
Aggregations