public class SessionUtil extends Object
SessionUtil provides a mechanism to assign the inactive
interval for the current session. In the event that user has more than one
thread accessing the same or separate assessments, SessionUtil
guarantees that the session will have the (maximum assessment time limit among threads)
as the value of the inactive interval.
Scenarios which require a greater inactive interval than the default interval:
- Assessments or surveys which are delivered on a single page
- Questions which require more time than the default application timeout setting
HttpSession,
HttpSession.setMaxInactiveInterval(int)| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_APP_INTERVAL_VAL |
static String |
EXTERNAL_APP_INTERVAL |
static int |
HOURS_TO_SECONDS_MULTIPLIER |
static int |
MINUTES_TO_SECONDS_MULTIPLIER |
| Constructor and Description |
|---|
SessionUtil() |
| Modifier and Type | Method and Description |
|---|---|
static void |
setSessionTimeout(javax.faces.context.FacesContext context,
DeliveryBean delivery,
boolean beginAssessment)
Sets the current
HttpSession maxInactiveInterval value |
public static final String EXTERNAL_APP_INTERVAL
public static final int HOURS_TO_SECONDS_MULTIPLIER
public static final int MINUTES_TO_SECONDS_MULTIPLIER
public static final int DEFAULT_APP_INTERVAL_VAL
public static void setSessionTimeout(javax.faces.context.FacesContext context,
DeliveryBean delivery,
boolean beginAssessment)
HttpSession maxInactiveInterval valuecontext - the faces contextdelivery - the delivery beanbeginAssessment - true if called from the beginning of an assessment, otherwise falseDeliveryBeanCopyright © 2005-2014 Sakai Project. All Rights Reserved.