|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.slim3.struts.test.MockServletConfig
public class MockServletConfig
A mock implementation for ServletConfig.
| Field Summary | |
|---|---|
protected Map<String,String> |
initParameterMap
The map table for initial parameters. |
protected ServletContext |
servletContext
The servlet context. |
protected String |
servletName
The servlet name. |
| Constructor Summary | |
|---|---|
MockServletConfig(ServletContext servletContext)
Constructor. |
|
| Method Summary | |
|---|---|
String |
getInitParameter(String name)
|
Enumeration<String> |
getInitParameterNames()
|
ServletContext |
getServletContext()
|
String |
getServletName()
Returns the servlet name. |
void |
removeInitParameter(String name)
Removes the initial parameter. |
void |
setInitParameter(String name,
String value)
Sets the initial parameter |
void |
setServletName(String servletName)
Sets the servlet name. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String servletName
protected ServletContext servletContext
protected Map<String,String> initParameterMap
| Constructor Detail |
|---|
public MockServletConfig(ServletContext servletContext)
throws NullPointerException
servletContext - the servlet context
NullPointerException - if the servletContext parameter is null| Method Detail |
|---|
public String getServletName()
getServletName in interface ServletConfigpublic void setServletName(String servletName)
servletName - the servlet namepublic ServletContext getServletContext()
getServletContext in interface ServletConfigpublic String getInitParameter(String name)
getInitParameter in interface ServletConfig
public void setInitParameter(String name,
String value)
name - the initial parameter namevalue - the valuepublic void removeInitParameter(String name)
name - the parameter namepublic Enumeration<String> getInitParameterNames()
getInitParameterNames in interface ServletConfig
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||