Definition at line 85 of file Serve.java.
Public Member Functions | |
Serve (Hashtable arguments, PrintStream logStream) | |
Constructor. | |
Serve () | |
void | addServlet (String urlPat, String className) |
Register a Servlet by class name. Registration consists of a URL. | |
void | addServlet (String urlPat, String className, Hashtable initParams) |
void | addServlet (String urlPat, Servlet servlet) |
Register a Servlet. Registration consists of a URL pattern,. | |
void | addServlet (String urlPat, Servlet servlet, Hashtable initParams) |
void | addDefaultServlets (String cgi) |
Register a standard set of Servlets. These will return. | |
void | addDefaultServlets (String cgi, String throttles) throws IOException |
Register a standard set of Servlets, with throttles. | |
void | serve () |
Servlet | getServlet (String name) |
Gets a servlet by name. | |
Enumeration | getServlets () |
Enumerates the servlets in this context (server). Only servlets that. | |
Enumeration | getServletNames () |
Enumerates the names of the servlets in this context (server). Only. | |
void | destroyAllServlets () |
Destroys all currently-loaded servlets. | |
void | setMappingTable (PathTreeDictionary mappingtable) |
void | setRealms (PathTreeDictionary realms) |
void | log (String message) |
Write information to the servlet log. | |
void | log (String message, Throwable throwable) |
void | log (Exception exception, String message) |
Write a stack trace to the servlet log. | |
String | getRealPath (String path) |
Applies alias rules to the specified virtual path and returns the. | |
String | getMimeType (String file) |
Returns the MIME type of the specified file. | |
String | getServerInfo () |
Returns the name and version of the web server under which the servlet. | |
Object | getAttribute (String name) |
Returns the value of the named attribute of the network service, or. | |
void | removeAttribute (String name) |
void | setAttribute (String name, Object object) |
Enumeration | getAttributeNames () |
ServletContext | getContext (String uripath) |
int | getMajorVersion () |
int | getMinorVersion () |
java.util.Set | getResourcePaths (java.lang.String path) |
Returns a directory-like listing of all the paths to resources within the web application whose longest sub-path matches the supplied path argument. | |
java.lang.String | getServletContextName () |
Returns the name of this web application correponding to this ServletContext as specified in the deployment descriptor for this web application by the display-name element. | |
URL | getResource (String path) throws MalformedURLException |
InputStream | getResourceAsStream (String path) |
RequestDispatcher | getRequestDispatcher (String urlpath) |
String | getInitParameter (String param) |
Enumeration | getInitParameterNames () |
RequestDispatcher | getNamedDispatcher (String name) |
void | forward (ServletRequest _request, ServletResponse _response) throws ServletException, java.io.IOException |
void | include (ServletRequest _request, ServletResponse _response) throws ServletException, java.io.IOException |
Static Public Member Functions | |
static void | main (String[] args) |
Main routine, if you want to run this directly as an application. | |
Static Public Attributes | |
static final String | ARG_PORT = "port" |
static final String | ARG_THROTTLES = "throttles" |
static final String | ARG_SERVLETS = "servlets" |
static final String | ARG_REALMS = "realms" |
static final String | ARG_ALIASES = "aliases" |
static final String | ARG_CGI_PATH = "cgi-path" |
static final String | ARG_SESSION_TIMEOUT = "session-timeout" |
static final String | ARG_LOG_OPTIONS = "log-options" |
static final String | ARG_SOCKET_FACTORY = "socketFactory" |
Protected Member Functions | |
ServerSocket | createServerSocket () throws IOException |
Protected Attributes | |
PathTreeDictionary | registry |
PathTreeDictionary | realms |
Hashtable | arguments |
Static Protected Attributes | |
static final int | DEF_SESSION_TIMEOUT = 30 |
static final int | DEF_PORT = 9090 |
Package Functions | |
void | setAccessLogged () |
boolean | isAccessLogged () |
boolean | isShowReferer () |
boolean | isShowUserAgent () |
Object | getSession (String id) |
HttpSession | createSession () |
void | removeSession (String id) |
synchronized String | generateSessionId () |
Package Attributes | |
int | port |
String | hostName |
sun.misc.BASE64Decoder | base64Dec = new sun.misc.BASE64Decoder() |
int | uniqer |
HttpSessionContextImpl | sessions |
boolean | running = true |
Static Package Attributes | |
static int | expiredIn |
Classes | |
class | Identification |
interface | SocketFactory |
|
Returns a directory-like listing of all the paths to resources within the web application whose longest sub-path matches the supplied path argument. Paths indicating subdirectory paths end with a '/'. The returned paths are all relative to the root of the web application and have a leading '/'. For example, for a web application containing
/welcome.html
getResourcePaths("/") returns {"/welcome.html", "/catalog/", "/customer/", "/WEB-INF/"}
Definition at line 882 of file Serve.java. |
|
Returns the name of this web application correponding to this ServletContext as specified in the deployment descriptor for this web application by the display-name element.
Definition at line 893 of file Serve.java. |
|
Main routine, if you want to run this directly as an application. format path mapping from=givenpath;dir=realpath format realmname=path,user:password,,,, Definition at line 102 of file Serve.java. References Acme.Serve.Serve.ARG_ALIASES, Acme.Serve.Serve.ARG_CGI_PATH, Acme.Serve.Serve.ARG_LOG_OPTIONS, Acme.Serve.Serve.ARG_PORT, Acme.Serve.Serve.ARG_REALMS, Acme.Serve.Serve.ARG_SERVLETS, Acme.Serve.Serve.ARG_SESSION_TIMEOUT, Acme.Serve.Serve.ARG_THROTTLES, Acme.Serve.Serve.arguments, Acme.Serve.PathTreeDictionary.put(), Acme.Serve.Serve.readServlets(), Acme.Serve.Serve.realms, Acme.Serve.Serve.Serve(), Acme.Serve.Serve.serve(), Acme.Serve.Serve.setMappingTable(), and Acme.Serve.Serve.setRealms(). |