JspServletContext.java 3.37 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  javax.servlet.RequestDispatcher
 *  javax.servlet.Servlet
 *  javax.servlet.ServletContext
 *  javax.servlet.ServletException
 */
package com.day.crx.explorer.impl;

import java.io.InputStream;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.Collections;
import java.util.Enumeration;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import javax.servlet.RequestDispatcher;
import javax.servlet.Servlet;
import javax.servlet.ServletContext;
import javax.servlet.ServletException;

public class JspServletContext
implements ServletContext {
    private final ServletContext delegatee;
    private final Map<String, Object> attributes = new HashMap<String, Object>();

    public JspServletContext(ServletContext delegatee) {
        this.delegatee = delegatee;
    }

    public ServletContext getContext(String uripath) {
        return this.delegatee.getContext(uripath);
    }

    public int getMajorVersion() {
        return this.delegatee.getMajorVersion();
    }

    public int getMinorVersion() {
        return this.delegatee.getMinorVersion();
    }

    public String getMimeType(String file) {
        return this.delegatee.getMimeType(file);
    }

    public Set getResourcePaths(String path) {
        return this.delegatee.getResourcePaths(path);
    }

    public URL getResource(String path) throws MalformedURLException {
        return this.delegatee.getResource(path);
    }

    public InputStream getResourceAsStream(String path) {
        return this.delegatee.getResourceAsStream(path);
    }

    public RequestDispatcher getRequestDispatcher(String path) {
        return this.delegatee.getRequestDispatcher(path);
    }

    public RequestDispatcher getNamedDispatcher(String name) {
        return this.delegatee.getNamedDispatcher(name);
    }

    public Servlet getServlet(String name) throws ServletException {
        return this.delegatee.getServlet(name);
    }

    public Enumeration getServlets() {
        return this.delegatee.getServlets();
    }

    public Enumeration getServletNames() {
        return this.delegatee.getServletNames();
    }

    public void log(String msg) {
        this.delegatee.log(msg);
    }

    public void log(Exception exception, String msg) {
        this.delegatee.log(exception, msg);
    }

    public void log(String message, Throwable throwable) {
        this.delegatee.log(message, throwable);
    }

    public String getRealPath(String path) {
        return this.delegatee.getRealPath(path);
    }

    public String getServerInfo() {
        return this.delegatee.getServerInfo();
    }

    public String getInitParameter(String name) {
        return this.delegatee.getInitParameter(name);
    }

    public Enumeration getInitParameterNames() {
        return this.delegatee.getInitParameterNames();
    }

    public Object getAttribute(String name) {
        return this.attributes.get(name);
    }

    public Enumeration getAttributeNames() {
        return Collections.enumeration(this.attributes.keySet());
    }

    public void setAttribute(String name, Object object) {
        this.attributes.put(name, object);
    }

    public void removeAttribute(String name) {
        this.attributes.remove(name);
    }

    public String getServletContextName() {
        return this.delegatee.getServletContextName();
    }
}