Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
portal-1.0.0, portal-2.0.0, portal-3.0.0, util-1.0.0, util-2.0.0, util-3.0.0
-
None
Description
This task involves adding methods to FacesContextHelper that take FacesContext and correspond to existing methods. The implementation of these methods should be called from the methods that do not take FacesContext. For example:
public void setSessionAttribute(String name, Object value) { setSessionAttribute(FacesContext.getCurrentInstance(), name, value); } public void setSessionAttribute(FacesContext facesContext, String name, Object value) { ExternalContext externalContext = facesContext.getExternalContext(); Map<String, Object> sessionMap = externalContext.getSessionMap(); sessionMap.put(name, value); }