|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.savarese.barehttp.Main
public final class Main
The BareHTTP server, a sample program that starts an HTTPServer
instance. The program expects two arguments: a port
number and a fully-qualified directory pathname specifying the
document root. It could easily be expanded to allow the
specification of a binding address and maximum number of
connections.
| Method Summary | |
|---|---|
static void |
main(java.lang.String[] args)
Starts an HTTPServer instance on a specified port
allowing HTTPServer.DEFAULT_MAX_CONNECTIONS. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static void main(java.lang.String[] args)
throws java.io.IOException
HTTPServer instance on a specified port
allowing HTTPServer.DEFAULT_MAX_CONNECTIONS. No
provisions are made for terminating the program. The program
must be terminated by SIGKILL, Ctrl-C, or whatever OS-specific
mechanism exists to kill a running process.
args - The program arguments: a port number and document
root directory. The root directory is converted to a canonical
path prior to starting the server.
java.lang.Exception - if the HTTPServer cannot be instantiated
or started.
java.io.IOException
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||