if (sessionAttributeSet != null &&
(sessionAttributeSet.contains(attrName) || sessionAttributeSet.contains(param.getParameterType())) &&
!implicitModel.containsKey(attrName)) {
HttpSession session = request.getSession(false);
if (session == null) {
throw new HttpSessionRequiredException(
"No session found - session required for attribute '" + attrName + "'");
}
Object sessionAttr = sessionAttributeStore.retrieveAttribute(webRequest, attrName);
if (sessionAttr == null) {
throw new HttpSessionRequiredException(
"Session attribute '" + attrName + "' required - not found in session");
}
sessionAttrNames.add(attrName);
implicitModel.addAttribute(attrName, sessionAttr);
}