| |
|
| java.lang.Object com.quadcap.http.server22.WebApplication
WebApplication | public class WebApplication implements ServletContext(Code) | | This class provides a wrapper for a Web Application, implementing
the application's ServletContext interface.
author: Stan Bailes |
Method Summary | |
public void | addInitParam(String prop, String val) | void | addMimeMapping(String ext, String type) | public void | addServlet(WebServlet servlet) | public void | addServletMapping(String servletName, String urlPattern) | public void | addWelcomeFile(String s) | public HSession | createSession() | public void | expireSessions() | public Object | getAttribute(String name) | public Enumeration | getAttributeNames() | final ClassLoader | getClassLoader() | public ServletContext | getContext(String path) | public String | getContextClassPath() Return the classpath for the context's libraries and classes
under WEB-INF. | public String | getContextPath() | public String | getDisplayName() | public String | getErrorPage() | public String | getInitParameter(String name) | public Enumeration | getInitParameterNames() | public int | getMajorVersion() | public String | getMimeType(String file) | public int | getMinorVersion() | public RequestDispatcher | getNamedDispatcher(String name) | public String | getRealPath(String path) | public RequestDispatcher | getRelativeRequestDispatcher(String path, HttpRequest base) | public RequestDispatcher | getRequestDispatcher(String path) | public URL | getResource(String path) | public InputStream | getResourceAsStream(String path) | public String | getRootPath() | public String | getServerInfo() Returns the name and version of the network service under which the
servlet is running. | public Servlet | getServlet(String name) | WebServlet | getServletForRequest(HttpDispatcher rd) | public Enumeration | getServletNames() | public Enumeration | getServlets() | public HSession | getSession(String sessionId) Returns the session bound to the specified session ID. | public int | getSessionTimeout() | public WebServer | getWebServer() | public List | getWelcomeFiles() | public void | init(WebServer server, String root, Directory dir) | public boolean | isDirectory(String d) | final void | loadInitialServlets() | public void | log(String msg) Writes a message to the server's log file. | public void | log(Exception e, String msg) Write the stack backtrace for the exception and the specified message
to the server's log file. | public void | log(String msg, Throwable e) Write the stack backtrace for the exception and the specified message
to the server's log file. | void | parseDeploymentDescriptor(Reader r) | public void | removeAttribute(String name) | void | removeSession(HSession session) | String | resolveDirectory(String path) If a URI refers to a directory, use the welcome file list to find
a resource in the directory to serve. | final void | resolveServlets(Hashtable t) | public void | setAttribute(String name, Object val) | public void | setDisplayName(String name) | public void | setErrorPage(String errorPage) | public void | setSessionTimeout(int timeout) | public void | shutdown() | public String | toString() |
sessionCount | long sessionCount(Code) | | |
sessionTimeout | int sessionTimeout(Code) | | |
welcomeFiles | List welcomeFiles(Code) | | Welcome file list
|
WebApplication | public WebApplication()(Code) | | |
addServletMapping | public void addServletMapping(String servletName, String urlPattern)(Code) | | |
createSession | public HSession createSession()(Code) | | Create a new session
|
expireSessions | public void expireSessions()(Code) | | Reap any expired sessions (sessions not active during the last
interval)
|
getContextClassPath | public String getContextClassPath()(Code) | | Return the classpath for the context's libraries and classes
under WEB-INF.
|
getMajorVersion | public int getMajorVersion()(Code) | | Return the server major version number
|
getMinorVersion | public int getMinorVersion()(Code) | | Return the server minor version number
|
getRequestDispatcher | public RequestDispatcher getRequestDispatcher(String path)(Code) | | Parameters: path - is a string that must begin with '/' and is interpretedrelative to this context's root |
getServerInfo | public String getServerInfo()(Code) | | Returns the name and version of the network service under which the
servlet is running.
the server information string |
getSession | public HSession getSession(String sessionId)(Code) | | Returns the session bound to the specified session ID.
Parameters: sessionID - the ID of a particular session object the session name. Returns null if the session ID does not referto a valid session. |
getSessionTimeout | public int getSessionTimeout()(Code) | | |
getWelcomeFiles | public List getWelcomeFiles()(Code) | | |
log | public void log(String msg)(Code) | | Writes a message to the server's log file.
Parameters: msg - the message |
log | public void log(Exception e, String msg)(Code) | | Write the stack backtrace for the exception and the specified message
to the server's log file.
Parameters: e - the exception Parameters: msg - the message |
log | public void log(String msg, Throwable e)(Code) | | Write the stack backtrace for the exception and the specified message
to the server's log file.
Parameters: e - the exception Parameters: msg - the message |
removeAttribute | public void removeAttribute(String name)(Code) | | |
resolveDirectory | String resolveDirectory(String path)(Code) | | If a URI refers to a directory, use the welcome file list to find
a resource in the directory to serve. Return the name of the file
if found, otherwise, simply return the original directory name.
|
setErrorPage | public void setErrorPage(String errorPage)(Code) | | |
setSessionTimeout | public void setSessionTimeout(int timeout)(Code) | | |
shutdown | public void shutdown()(Code) | | |
|
|
|