|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnextapp.echoservlet.tests.MockSession
public class MockSession
This class is a mock object for unit testing, it implements the HttpSession interface.
| Constructor Summary | |
|---|---|
MockSession()
|
|
| Method Summary | |
|---|---|
java.lang.Object |
getAttribute(java.lang.String arg0)
|
java.util.Enumeration |
getAttributeNames()
|
long |
getCreationTime()
|
java.lang.String |
getId()
|
long |
getLastAccessedTime()
|
int |
getMaxInactiveInterval()
|
javax.servlet.ServletContext |
getServletContext()
|
javax.servlet.http.HttpSessionContext |
getSessionContext()
Deprecated. |
java.lang.Object |
getValue(java.lang.String arg0)
Deprecated. |
java.lang.String[] |
getValueNames()
Deprecated. |
void |
invalidate()
|
boolean |
isNew()
|
void |
putValue(java.lang.String arg0,
java.lang.Object arg1)
Deprecated. |
void |
removeAttribute(java.lang.String arg0)
|
void |
removeValue(java.lang.String arg0)
Deprecated. |
void |
setAttribute(java.lang.String arg0,
java.lang.Object arg1)
|
void |
setMaxInactiveInterval(int arg0)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MockSession()
| Method Detail |
|---|
public long getCreationTime()
getCreationTime in interface javax.servlet.http.HttpSessionpublic java.lang.String getId()
getId in interface javax.servlet.http.HttpSessionpublic long getLastAccessedTime()
getLastAccessedTime in interface javax.servlet.http.HttpSessionpublic javax.servlet.ServletContext getServletContext()
getServletContext in interface javax.servlet.http.HttpSessionpublic void setMaxInactiveInterval(int arg0)
setMaxInactiveInterval in interface javax.servlet.http.HttpSessionpublic int getMaxInactiveInterval()
getMaxInactiveInterval in interface javax.servlet.http.HttpSessionpublic javax.servlet.http.HttpSessionContext getSessionContext()
getSessionContext in interface javax.servlet.http.HttpSessionHttpSession.getSessionContext()public java.lang.Object getAttribute(java.lang.String arg0)
getAttribute in interface javax.servlet.http.HttpSessionpublic java.lang.Object getValue(java.lang.String arg0)
getValue in interface javax.servlet.http.HttpSessionHttpSession.getValue(java.lang.String)public java.util.Enumeration getAttributeNames()
getAttributeNames in interface javax.servlet.http.HttpSessionHttpSession.getAttributeNames()public java.lang.String[] getValueNames()
getValueNames in interface javax.servlet.http.HttpSessionHttpSession.getValueNames()
public void setAttribute(java.lang.String arg0,
java.lang.Object arg1)
setAttribute in interface javax.servlet.http.HttpSessionHttpSession.setAttribute(java.lang.String,
java.lang.Object)
public void putValue(java.lang.String arg0,
java.lang.Object arg1)
putValue in interface javax.servlet.http.HttpSessionHttpSession.putValue(java.lang.String,
java.lang.Object)public void removeAttribute(java.lang.String arg0)
removeAttribute in interface javax.servlet.http.HttpSessionpublic void removeValue(java.lang.String arg0)
removeValue in interface javax.servlet.http.HttpSessionHttpSession.removeValue(java.lang.String)public void invalidate()
invalidate in interface javax.servlet.http.HttpSessionpublic 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 | ||||||||