Class MockHttpSession
java.lang.Object
org.exoplatform.services.test.mock.MockHttpSession
- All Implemented Interfaces:
jakarta.servlet.http.HttpSession
The Class MockHttpSession.
- Version:
- $Id: $
- Author:
- Max Shaposhnik
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlonggetId()longintjakarta.servlet.ServletContextString[]voidbooleanisNew()booleanisValid()Checks if is valid.voidvoidvoidvoidsetAttribute(String s, Object o) voidsetMaxInactiveInterval(int i) voidsetValid(boolean isValid) Sets the valid.
-
Constructor Details
-
MockHttpSession
public MockHttpSession()
-
-
Method Details
-
getCreationTime
public long getCreationTime()- Specified by:
getCreationTimein interfacejakarta.servlet.http.HttpSession
-
getId
- Specified by:
getIdin interfacejakarta.servlet.http.HttpSession
-
getLastAccessedTime
public long getLastAccessedTime()- Specified by:
getLastAccessedTimein interfacejakarta.servlet.http.HttpSession
-
getServletContext
public jakarta.servlet.ServletContext getServletContext()- Specified by:
getServletContextin interfacejakarta.servlet.http.HttpSession
-
setMaxInactiveInterval
public void setMaxInactiveInterval(int i) - Specified by:
setMaxInactiveIntervalin interfacejakarta.servlet.http.HttpSession
-
getMaxInactiveInterval
public int getMaxInactiveInterval()- Specified by:
getMaxInactiveIntervalin interfacejakarta.servlet.http.HttpSession
-
getAttribute
- Specified by:
getAttributein interfacejakarta.servlet.http.HttpSession
-
getValue
-
getAttributeNames
- Specified by:
getAttributeNamesin interfacejakarta.servlet.http.HttpSession
-
getValueNames
-
setAttribute
- Specified by:
setAttributein interfacejakarta.servlet.http.HttpSession
-
putValue
-
removeAttribute
- Specified by:
removeAttributein interfacejakarta.servlet.http.HttpSession
-
removeValue
-
invalidate
public void invalidate()- Specified by:
invalidatein interfacejakarta.servlet.http.HttpSession
-
isNew
public boolean isNew()- Specified by:
isNewin interfacejakarta.servlet.http.HttpSession
-
isValid
public boolean isValid()Checks if is valid.- Returns:
- true, if is valid
-
setValid
public void setValid(boolean isValid) Sets the valid.- Parameters:
isValid- the new valid
-