📄 portletservletcontext.java
字号:
// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://kpdus.tripod.com/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi space
// Source File Name: PortletServletContext.java
package org.apache.struts2.portlet.servlet;
import java.io.InputStream;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.Enumeration;
import java.util.Set;
import javax.portlet.PortletContext;
import javax.servlet.*;
// Referenced classes of package org.apache.struts2.portlet.servlet:
// PortletServletRequestDispatcher
public class PortletServletContext
implements ServletContext
{
private PortletContext portletContext;
public PortletServletContext(PortletContext portletContext)
{
this.portletContext = portletContext;
}
public Object getAttribute(String name)
{
return portletContext.getAttribute(name);
}
public Enumeration getAttributeNames()
{
return portletContext.getAttributeNames();
}
public ServletContext getContext(String uripath)
{
throw new IllegalStateException("Not supported in a portlet");
}
public String getInitParameter(String name)
{
return portletContext.getInitParameter(name);
}
public Enumeration getInitParameterNames()
{
return portletContext.getInitParameterNames();
}
public int getMajorVersion()
{
return portletContext.getMajorVersion();
}
public String getMimeType(String file)
{
return portletContext.getMimeType(file);
}
public int getMinorVersion()
{
return portletContext.getMinorVersion();
}
public RequestDispatcher getNamedDispatcher(String name)
{
return new PortletServletRequestDispatcher(portletContext.getNamedDispatcher(name));
}
public String getRealPath(String path)
{
return portletContext.getRealPath(path);
}
public RequestDispatcher getRequestDispatcher(String path)
{
return new PortletServletRequestDispatcher(portletContext.getRequestDispatcher(path));
}
public URL getResource(String path)
throws MalformedURLException
{
return portletContext.getResource(path);
}
public InputStream getResourceAsStream(String path)
{
return portletContext.getResourceAsStream(path);
}
public Set getResourcePaths(String path)
{
return portletContext.getResourcePaths(path);
}
public String getServerInfo()
{
return portletContext.getServerInfo();
}
public Servlet getServlet(String name)
throws ServletException
{
throw new IllegalStateException("Not allowed in a portlet");
}
public String getServletContextName()
{
return portletContext.getPortletContextName();
}
public Enumeration getServletNames()
{
throw new IllegalStateException("Not allowed in a portlet");
}
public Enumeration getServlets()
{
throw new IllegalStateException("Not allowed in a portlet");
}
public void log(String msg)
{
portletContext.log(msg);
}
public void log(Exception exception, String msg)
{
log(msg, ((Throwable) (exception)));
}
public void log(String message, Throwable throwable)
{
portletContext.log(message, throwable);
}
public void removeAttribute(String name)
{
portletContext.removeAttribute(name);
}
public void setAttribute(String name, Object object)
{
portletContext.setAttribute(name, object);
}
public PortletContext getPortletContext()
{
return portletContext;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -