Java Doc for MockServletContext.java in  » Testing » mockrunner-0.4 » com » mockrunner » mock » web » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Testing » mockrunner 0.4 » com.mockrunner.mock.web 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.mockrunner.mock.web.MockServletContext

MockServletContext
public class MockServletContext implements ServletContext(Code)
Mock implementation of ServletContext.



Constructor Summary
public  MockServletContext()
    

Method Summary
public synchronized  voidaddAttributeListener(ServletContextAttributeListener listener)
    
public synchronized  voidaddResourcePath(String path, String resourcePath)
    
public synchronized  voidaddResourcePaths(String path, Collection pathes)
    
public synchronized  voidclearAttributes()
    
public synchronized  voidclearInitParameters()
     Clears the init parameters.
public synchronized  voidclearRequestDispatcherMap()
     Clears the map of RequestDispatcher objects.
public synchronized  ObjectgetAttribute(String key)
    
public synchronized  EnumerationgetAttributeNames()
    
public synchronized  ServletContextgetContext(String url)
    
public  StringgetContextPath()
    
public synchronized  StringgetInitParameter(String name)
    
public synchronized  EnumerationgetInitParameterNames()
    
public synchronized  intgetMajorVersion()
    
public synchronized  StringgetMimeType(String file)
    
public synchronized  intgetMinorVersion()
    
public synchronized  RequestDispatchergetNamedDispatcher(String name)
    
public synchronized  StringgetRealPath(String path)
    
public synchronized  RequestDispatchergetRequestDispatcher(String path)
    
public synchronized  MapgetRequestDispatcherMap()
     Returns the map of RequestDispatcher objects.
public synchronized  URLgetResource(String path)
    
public synchronized  InputStreamgetResourceAsStream(String path)
    
public synchronized  SetgetResourcePaths(String path)
    
public synchronized  StringgetServerInfo()
    
public synchronized  ServletgetServlet(String arg0)
    
public synchronized  StringgetServletContextName()
    
public synchronized  EnumerationgetServletNames()
    
public synchronized  EnumerationgetServlets()
    
public synchronized  voidlog(Exception exc, String message)
    
public synchronized  voidlog(String message, Throwable exc)
    
public synchronized  voidlog(String message)
    
public synchronized  voidremoveAttribute(String key)
    
public synchronized  voidresetAll()
    
public synchronized  voidsetAttribute(String key, Object value)
    
public synchronized  voidsetContext(String url, ServletContext context)
    
public  voidsetContextPath(String contextPath)
    
public synchronized  voidsetInitParameter(String name, String value)
     Sets an init parameter.
public synchronized  voidsetInitParameters(Map parameters)
     Sets several init parameters.
public synchronized  voidsetMimeType(String file, String type)
    
public synchronized  voidsetRealPath(String path, String realPath)
    
public synchronized  voidsetRequestDispatcher(String path, RequestDispatcher dispatcher)
     Sets a RequestDispatcher that will be returned when calling MockServletContext.getRequestDispatcher or MockServletContext.getNamedDispatcher with the specified path or name.
public synchronized  voidsetResource(String path, URL url)
    
public synchronized  voidsetResourceAsStream(String path, InputStream inputStream)
    
public synchronized  voidsetResourceAsStream(String path, byte[] data)
    
public synchronized  voidsetServletContextName(String servletContextName)
    


Constructor Detail
MockServletContext
public MockServletContext()(Code)




Method Detail
addAttributeListener
public synchronized void addAttributeListener(ServletContextAttributeListener listener)(Code)



addResourcePath
public synchronized void addResourcePath(String path, String resourcePath)(Code)



addResourcePaths
public synchronized void addResourcePaths(String path, Collection pathes)(Code)



clearAttributes
public synchronized void clearAttributes()(Code)



clearInitParameters
public synchronized void clearInitParameters()(Code)
Clears the init parameters.



clearRequestDispatcherMap
public synchronized void clearRequestDispatcherMap()(Code)
Clears the map of RequestDispatcher objects.



getAttribute
public synchronized Object getAttribute(String key)(Code)



getAttributeNames
public synchronized Enumeration getAttributeNames()(Code)



getContext
public synchronized ServletContext getContext(String url)(Code)



getContextPath
public String getContextPath()(Code)



getInitParameter
public synchronized String getInitParameter(String name)(Code)



getInitParameterNames
public synchronized Enumeration getInitParameterNames()(Code)



getMajorVersion
public synchronized int getMajorVersion()(Code)



getMimeType
public synchronized String getMimeType(String file)(Code)



getMinorVersion
public synchronized int getMinorVersion()(Code)



getNamedDispatcher
public synchronized RequestDispatcher getNamedDispatcher(String name)(Code)



getRealPath
public synchronized String getRealPath(String path)(Code)



getRequestDispatcher
public synchronized RequestDispatcher getRequestDispatcher(String path)(Code)



getRequestDispatcherMap
public synchronized Map getRequestDispatcherMap()(Code)
Returns the map of RequestDispatcher objects. The specified path maps to the corresponding RequestDispatcher object. the map of RequestDispatcher objects



getResource
public synchronized URL getResource(String path) throws MalformedURLException(Code)



getResourceAsStream
public synchronized InputStream getResourceAsStream(String path)(Code)



getResourcePaths
public synchronized Set getResourcePaths(String path)(Code)



getServerInfo
public synchronized String getServerInfo()(Code)



getServlet
public synchronized Servlet getServlet(String arg0) throws ServletException(Code)



getServletContextName
public synchronized String getServletContextName()(Code)



getServletNames
public synchronized Enumeration getServletNames()(Code)



getServlets
public synchronized Enumeration getServlets()(Code)



log
public synchronized void log(Exception exc, String message)(Code)



log
public synchronized void log(String message, Throwable exc)(Code)



log
public synchronized void log(String message)(Code)



removeAttribute
public synchronized void removeAttribute(String key)(Code)



resetAll
public synchronized void resetAll()(Code)
Resets the state of this object to the default values



setAttribute
public synchronized void setAttribute(String key, Object value)(Code)



setContext
public synchronized void setContext(String url, ServletContext context)(Code)
Sets a ServletContext that will be returned when calling MockServletContext.getContext
Parameters:
  url - the URL
Parameters:
  context - the ServletContext



setContextPath
public void setContextPath(String contextPath)(Code)



setInitParameter
public synchronized void setInitParameter(String name, String value)(Code)
Sets an init parameter.
Parameters:
  name - the name
Parameters:
  value - the value



setInitParameters
public synchronized void setInitParameters(Map parameters)(Code)
Sets several init parameters.
Parameters:
  parameters - the parameter map



setMimeType
public synchronized void setMimeType(String file, String type)(Code)



setRealPath
public synchronized void setRealPath(String path, String realPath)(Code)



setRequestDispatcher
public synchronized void setRequestDispatcher(String path, RequestDispatcher dispatcher)(Code)
Sets a RequestDispatcher that will be returned when calling MockServletContext.getRequestDispatcher or MockServletContext.getNamedDispatcher with the specified path or name. If no RequestDispatcher is set for the specified path, MockServletContext.getRequestDispatcher and MockServletContext.getNamedDispatcher automatically create a new one.
Parameters:
  path - the path for the RequestDispatcher
Parameters:
  dispatcher - the RequestDispatcher object



setResource
public synchronized void setResource(String path, URL url)(Code)



setResourceAsStream
public synchronized void setResourceAsStream(String path, InputStream inputStream)(Code)



setResourceAsStream
public synchronized void setResourceAsStream(String path, byte[] data)(Code)



setServletContextName
public synchronized void setServletContextName(String servletContextName)(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.