FileDocCategorySizeDatePackage
StrutsMockServletContext.javaAPI DocExample4273Mon Jul 23 13:26:16 BST 2007org.apache.struts2.views.jsp

StrutsMockServletContext

public class StrutsMockServletContext extends Object implements ServletContext
StrutsMockServletContext

Fields Summary
String
realPath
String
servletInfo
String
contextPath
Map
initParams
Map
attributes
InputStream
resourceAsStream
Constructors Summary
Methods Summary
public java.lang.ObjectgetAttribute(java.lang.String s)

        return attributes.get(s);
    
public java.util.EnumerationgetAttributeNames()

        return Collections.enumeration(attributes.keySet());
    
public javax.servlet.ServletContextgetContext(java.lang.String s)

        return null;
    
public java.lang.StringgetContextPath()

        return contextPath;
    
public java.lang.StringgetInitParameter(java.lang.String s)

        return (String) initParams.get(s);
    
public java.util.EnumerationgetInitParameterNames()

        return Collections.enumeration(initParams.keySet());
    
public intgetMajorVersion()

        return 0;
    
public java.lang.StringgetMimeType(java.lang.String s)

        return null;
    
public intgetMinorVersion()

        return 0;
    
public javax.servlet.RequestDispatchergetNamedDispatcher(java.lang.String s)

        return null;
    
public java.lang.StringgetRealPath(java.lang.String string)

        return realPath;
    
public javax.servlet.RequestDispatchergetRequestDispatcher(java.lang.String s)

        return null;
    
public java.net.URLgetResource(java.lang.String s)

        return null;
    
public java.io.InputStreamgetResourceAsStream(java.lang.String s)

        if (resourceAsStream != null) {
            return resourceAsStream;
        }
        return null;
    
public java.util.SetgetResourcePaths(java.lang.String s)

        return null;
    
public java.lang.StringgetServerInfo()

        return servletInfo;
    
public javax.servlet.ServletgetServlet(java.lang.String s)

        return null;
    
public java.lang.StringgetServletContextName()

        return null;
    
public java.util.EnumerationgetServletNames()

        return null;
    
public java.util.EnumerationgetServlets()

        return null;
    
public voidlog(java.lang.String s)

    
public voidlog(java.lang.Exception e, java.lang.String s)

    
public voidlog(java.lang.String s, java.lang.Throwable throwable)

    
public voidremoveAttribute(java.lang.String s)

        attributes.remove(s);
    
public voidsetAttribute(java.lang.String s, java.lang.Object o)

        attributes.put(s, o);
    
public voidsetContextPath(java.lang.String contextPath)

        this.contextPath = contextPath;
    
public voidsetInitParameter(java.lang.String name, java.lang.String value)


          
        initParams.put(name, value);
    
public voidsetRealPath(java.lang.String value)

        realPath = value;
    
public voidsetResourceAsStream(java.io.InputStream is)

        this.resourceAsStream = is;
    
public voidsetServletInfo(java.lang.String servletInfo)

        this.servletInfo = servletInfo;