home *** CD-ROM | disk | FTP | other *** search
Java Source | 2000-04-03 | 7.3 KB | 365 lines |
- /*
- * pageContext.java -- XXX
- *
- * Copyright (c) 1999 by Free Software Foundation, Inc.
- * Written by Mark Wielaard (mark@klomp.org)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Library General Public License as published
- * by the Free Software Foundation, version 2. (see COPYING.LIB)
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA
- */
-
- package javax.servlet.jsp;
-
- import java.io.IOException;
- import java.util.Enumeration;
- import java.util.Hashtable;
-
- import javax.servlet.Servlet;
- import javax.servlet.ServletConfig;
- import javax.servlet.ServletContext;
- import javax.servlet.ServletException;
- import javax.servlet.ServletRequest;
- import javax.servlet.ServletResponse;
- import javax.servlet.http.HttpSession;
- import javax.servlet.http.HttpServletRequest;
-
- /**
- * XXX
- */
- public abstract class PageContext {
-
- // static final ints used to denote the scope
- // [mjw] We don't know what the real values are XXX!!!
-
- /**
- * XXX
- */
- public static final int PAGE_SCOPE = 1; // XXX
-
- /**
- * XXX
- */
- public static final int REQUEST_SCOPE = 2; // XXX
-
- /**
- * XXX
- */
- public static final int SESSION_SCOPE = 3; // XXX
-
- /**
- * XXX
- */
- public static final int APPLICATION_SCOPE = 4; // XXX
-
- // static final strings used in attribute name table
- // [mjw] We don't know what the real values are XXX!!!
-
- /**
- * XXX
- */
- public static final String PAGE = "javax.servlet.jsp.jspPage";
-
-
- /**
- * XXX
- */
- public static final String PAGECONTEXT = "javax.servlet.jsp.jspPageContext";
-
-
- /**
- * XXX
- */
- public static final String REQUEST = "javax.servlet.jsp.jspRequest";
-
-
- /**
- * XXX
- */
- public static final String RESPONSE = "javax.servlet.jsp.jspResponse";
-
-
- /**
- * XXX
- */
- public static final String CONFIG = "javax.servlet.jsp.jspConfig";
-
-
- /**
- * XXX
- */
- public static final String SESSION = "javax.servlet.jsp.jspSession";
-
-
- /**
- * XXX
- */
- public static final String OUT = "javax.servlet.jsp.jspOut";
-
-
- /**
- * XXX
- */
- public static final String APPLICATION = "javax.servlet.jsp.jspApplication";
-
-
- /**
- * XXX
- */
- public static final String EXCEPTION = "javax.servlet.jsp.jspException";
-
-
- // Constructor
-
- public PageContext() {
- }
-
-
- /**
- * XXX
- *
- * @param servlet XXX
- * @param request XXX
- * @param response XXX
- * @param errorPageURL XXX
- * @param needsSession XXX
- * @param bufferSize XXX
- * @param autoflush XXX
- *
- * @exception IOException XXX
- * @exception IllegalStateException XXX
- * @exception IllegalArgumentException XXX
- */
- public abstract void initialize( Servlet servlet,
- ServletRequest request,
- ServletResponse response,
- String errorPageURL,
- boolean needsSession,
- int bufferSize,
- boolean autoflush) throws
- IOException,
- IllegalArgumentException,
- IllegalStateException;
-
- /**
- * XXX
- */
- public abstract void release();
-
-
- /**
- * XXX
- *
- * @param name XXX
- * @param attribute XXX
- * @exception NullPointerException XXX
- */
- public abstract void setAttribute(String name, Object attribute) throws
- NullPointerException;
-
- /**
- * XXX
- *
- * @param name XXX
- * @param attribute XXX
- * @param scope XXX
- *
- * @exception IllegalArgumentException XXX
- * @exception NullPointerException XXX
- */
- public abstract void setAttribute(String name,
- Object attribute,
- int scope)
- throws IllegalArgumentException,
- NullPointerException;
-
- /**
- * XXX
- *
- * @param name XXX
- * @return XXX
- *
- * @exception IllegalArgumentException XXX
- * @exception NullPointerException XXX
- */
- public abstract Object getAttribute(String name)
- throws IllegalArgumentException,
- NullPointerException;
-
- /**
- * XXX
- *
- * @param name XXX
- * @return XXX
- *
- * @exception IllegalArgumentException XXX
- * @exception NullPointerException XXX
- */
- public abstract Object getAttribute(String name, int scope)
- throws IllegalArgumentException,
- NullPointerException;
-
- /**
- * XXX
- *
- * @param name XXX
- */
- public abstract Object findAttribute(String name);
-
-
- /**
- * XXX
- *
- * @param name XXX
- */
- public abstract void removeAttribute(String name);
-
-
- /**
- * XXX
- *
- * @param name XXX
- * @param scope XXX
- */
- public abstract void removeAttribute(String name, int scope);
-
-
-
- /**
- * XXX
- *
- * @param scope XXX
- * @return XXX
- */
- public abstract int getAttributesScope(String name);
-
-
- /**
- * XXX
- *
- * @param scope XXX
- * @return XXX
- */
- public abstract Enumeration getAttributeNamesInScope(int scope);
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract JspWriter getOut();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract HttpSession getSession();
-
- /**
- * XXX
- *
- * @return the page in the form of a Servlet
- */
- public abstract Object getPage();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract ServletRequest getRequest();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract ServletResponse getResponse();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract Exception getException();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract ServletConfig getServletConfig();
-
-
- /**
- * XXX
- *
- * @return XXX
- */
- public abstract ServletContext getServletContext();
-
-
- /**
- * XXX
- *
- * @param urlPath XXX
- *
- * @exception IOException XXX
- * @exception ServletException XXX
- * @exception IllegalArgumentException XXX
- * @exception IllegalStateException XXX
- * @exception SecurityException XXX
- */
- public abstract void forward(String urlPath) throws
- IOException,
- ServletException,
- IllegalArgumentException,
- IllegalStateException,
- SecurityException;
-
- /**
- * XXX
- *
- * @param urlPath XXX
- *
- * @exception IOException XXX
- * @exception ServletException XXX
- * @exception IllegalArgumentException XXX
- * @exception SecurityException XXX
- */
- public abstract void include(String urlPath) throws
- IOException,
- ServletException,
- IllegalArgumentException,
- SecurityException;
-
-
- /**
- * XXX
- *
- * @param exception XXX
- *
- * @exception IOException XXX
- * @exception ServletException XXX
- */
- public abstract void handlePageException(Exception exception)
- throws IOException,
- ServletException;
- }
-