if (mergeSingleAttribute(context, "timeout", "session-config.session-timeout", "" + sessionConfig.getSessionTimeout(), null, elementSource)) {
getSessionConfig(webApp, context).setSessionTimeout(sessionConfig.getSessionTimeout());
}
}
if (sessionConfig.getCookieConfig() != null) {
CookieConfig cookieConfig = sessionConfig.getCookieConfig();
if (cookieConfig.getName() != null && mergeSingleAttribute(context, "name", "session-config.cookie-config.name", cookieConfig.getName(), null, elementSource)) {
getCookieConfig(webApp, context).setName(cookieConfig.getName());
}
if (cookieConfig.getDomain() != null && mergeSingleAttribute(context, "domain", "session-config.cookie-config.domain", cookieConfig.getDomain(), null, elementSource)) {
getCookieConfig(webApp, context).setDomain(cookieConfig.getDomain());
}
if (cookieConfig.getPath() != null && mergeSingleAttribute(context, "path", "session-config.cookie-config.path", cookieConfig.getPath(), null, elementSource)) {
getCookieConfig(webApp, context).setPath(cookieConfig.getPath());
}
if (cookieConfig.getComment() != null && mergeSingleAttribute(context, "comment", "session-config.cookie-config.comment", cookieConfig.getComment(), null, elementSource)) {
getCookieConfig(webApp, context).setComment(cookieConfig.getComment());
}
if (cookieConfig.getHttpOnly() != null && mergeSingleAttribute(context, "http-only", "session-config.cookie-config.http-only", "" + cookieConfig.getHttpOnly(), null, elementSource)) {
getCookieConfig(webApp, context).setHttpOnly(cookieConfig.getHttpOnly());
}
if (cookieConfig.getSecure() != null && mergeSingleAttribute(context, "secure", "session-config.cookie-config.secure", "" + cookieConfig.getSecure(), null, elementSource)) {
getCookieConfig(webApp, context).setSecure(cookieConfig.getSecure());
}
if (cookieConfig.getMaxAge() != null && mergeSingleAttribute(context, "max-age", "session-config.cookie-config.max-age", "" +cookieConfig.getMaxAge(), null, elementSource)) {
getCookieConfig(webApp, context).setMaxAge(cookieConfig.getMaxAge());
}
}
if (elementSource.equals(ElementSource.WEB_FRAGMENT) && !sessionConfig.getTrackingMode().isEmpty()) {
for (TrackingMode trackingMode : sessionConfig.getTrackingMode()) {
if (!context.containsAttribute("session-config.tracking-mode." + trackingMode)) {