|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ideo.sweetdevria.mock.MockHttpSession
public final class MockHttpSession
Mock HttpSession object used for "non web" context (exemple : the excel export in batch mode). This object implements only getter/setter methods for attributes.
Constructor Summary | |
---|---|
MockHttpSession(javax.servlet.ServletContext servletContext)
Default constructor. |
Method Summary | |
---|---|
java.lang.Object |
getAttribute(java.lang.String attributeName)
Get the object stored in the hash map under this attribute name. |
java.util.Enumeration |
getAttributeNames()
Get all attributes names. |
long |
getCreationTime()
Not implemented ! |
java.lang.String |
getId()
Not implemented ! |
long |
getLastAccessedTime()
Not implemented ! |
int |
getMaxInactiveInterval()
Not implemented ! |
javax.servlet.ServletContext |
getServletContext()
Not implemented ! |
javax.servlet.http.HttpSessionContext |
getSessionContext()
Deprecated. |
java.lang.Object |
getValue(java.lang.String attributeName)
Get the value from attribute. |
java.lang.String[] |
getValueNames()
Get value names. |
void |
invalidate()
Not implemented ! |
boolean |
isNew()
Not implemented ! |
void |
putValue(java.lang.String attributeName,
java.lang.Object object)
Set an object under the attribute name. |
void |
removeAttribute(java.lang.String attributeName)
Remove the attribute. |
void |
removeValue(java.lang.String attributeName)
Remove the attribute. |
void |
setAttribute(java.lang.String attributeName,
java.lang.Object attribute)
Set an object under the attribute name. |
void |
setMaxInactiveInterval(int i)
Not implemented ! |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MockHttpSession(javax.servlet.ServletContext servletContext)
servletContext
- Servlet contextMethod Detail |
---|
public java.lang.Object getAttribute(java.lang.String attributeName)
getAttribute
in interface javax.servlet.http.HttpSession
attributeName
- attribute name
public java.util.Enumeration getAttributeNames()
getAttributeNames
in interface javax.servlet.http.HttpSession
public void setAttribute(java.lang.String attributeName, java.lang.Object attribute)
setAttribute
in interface javax.servlet.http.HttpSession
attributeName
- Attribute name under which store the objectattribute
- object to storepublic void removeAttribute(java.lang.String attributeName)
removeAttribute
in interface javax.servlet.http.HttpSession
attributeName
- Attribute name under which store the objectpublic java.lang.Object getValue(java.lang.String attributeName)
getValue
in interface javax.servlet.http.HttpSession
attributeName
- Attribute name under which store the object
public java.lang.String[] getValueNames()
getValueNames
in interface javax.servlet.http.HttpSession
public void putValue(java.lang.String attributeName, java.lang.Object object)
putValue
in interface javax.servlet.http.HttpSession
attributeName
- Attribute name under which store the objectobject
- Value to storepublic void removeValue(java.lang.String attributeName)
removeValue
in interface javax.servlet.http.HttpSession
attributeName
- Attribute name under which store the objectpublic long getCreationTime()
getCreationTime
in interface javax.servlet.http.HttpSession
public java.lang.String getId()
getId
in interface javax.servlet.http.HttpSession
public long getLastAccessedTime()
getLastAccessedTime
in interface javax.servlet.http.HttpSession
public javax.servlet.ServletContext getServletContext()
getServletContext
in interface javax.servlet.http.HttpSession
public void setMaxInactiveInterval(int i)
setMaxInactiveInterval
in interface javax.servlet.http.HttpSession
i
- valuepublic int getMaxInactiveInterval()
getMaxInactiveInterval
in interface javax.servlet.http.HttpSession
public javax.servlet.http.HttpSessionContext getSessionContext()
getSessionContext
in interface javax.servlet.http.HttpSession
public void invalidate()
invalidate
in interface javax.servlet.http.HttpSession
public boolean isNew()
isNew
in interface javax.servlet.http.HttpSession
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |