com.mockobjects.servlet
public class MockServletContext extends MockObject implements ServletContext
Method Summary | |
---|---|
void | addExpectedAttribute(String key, Object value) |
void | addRealPath(String realPath) |
Object | getAttribute(String string) |
Enumeration | getAttributeNames() |
ServletContext | getContext(String string) |
String | getInitParameter(String paramName) |
Enumeration | getInitParameterNames() |
int | getMajorVersion() |
String | getMimeType(String string) |
int | getMinorVersion() |
RequestDispatcher | getNamedDispatcher(String string) |
String | getRealPath(String string) |
RequestDispatcher | getRequestDispatcher(String uri) |
URL | getResource(String string) |
InputStream | getResourceAsStream(String string) |
Set | getResourcePaths(String string) |
Set | getResourcePaths() |
String | getServerInfo() |
Servlet | getServlet(String string) |
String | getServletContextName() |
Enumeration | getServletNames() |
Enumeration | getServlets() |
void | log(String string) |
void | log(String string, Throwable t) |
void | log(Exception exception, String string) |
void | removeAttribute(String string) |
void | setAttribute(String key, Object value) |
void | setExpectedLog(String string) |
void | setExpectedLogThrowable(Throwable throwable) |
void | setExpectedRequestDispatcherURI(String uri) |
void | setInitParameter(String paramName, String paramValue) |
void | setupGetAttribute(String string, Object object) |
void | setupGetRequestDispatcher(RequestDispatcher requestDispatcher) |
void | setupGetResource(URL resource) |
void | setupGetResourcePaths(Set resourcePaths) |