test/sun/security/ssl/sun/net/www/httpstest/TestHttpsServer.java
Print this page
@@ -49,11 +49,11 @@
* corresponding change in the J2SE equivalent.
*
* NOTE NOTE NOTE NOTE NOTE NOTE NOTE
*/
-public class HttpServer {
+public class TestHttpsServer {
ServerSocketChannel schan;
int threads;
int cperthread;
HttpCallback cb;
@@ -61,40 +61,40 @@
// ssl related fields
static SSLContext sslCtx;
/**
- * Create a <code>HttpServer<code> instance with the specified callback object
+ * Create a <code>TestHttpsServer<code> instance with the specified callback object
* for handling requests. One thread is created to handle requests,
* and up to ten TCP connections will be handled simultaneously.
* @param cb the callback object which is invoked to handle each
* incoming request
*/
- public HttpServer (HttpCallback cb) throws IOException {
+ public TestHttpsServer (HttpCallback cb) throws IOException {
this (cb, 1, 10, 0);
}
/**
- * Create a <code>HttpServer<code> instance with the specified number of
+ * Create a <code>TestHttpsServer<code> instance with the specified number of
* threads and maximum number of connections per thread. This functions
* the same as the 4 arg constructor, where the port argument is set to zero.
* @param cb the callback object which is invoked to handle each
* incoming request
* @param threads the number of threads to create to handle requests
* in parallel
* @param cperthread the number of simultaneous TCP connections to
* handle per thread
*/
- public HttpServer (HttpCallback cb, int threads, int cperthread)
+ public TestHttpsServer (HttpCallback cb, int threads, int cperthread)
throws IOException {
this (cb, threads, cperthread, 0);
}
/**
- * Create a <code>HttpServer<code> instance with the specified number
+ * Create a <code>TestHttpsServer<code> instance with the specified number
* of threads and maximum number of connections per thread and running on
* the specified port. The specified number of threads are created to
* handle incoming requests, and each thread is allowed
* to handle a number of simultaneous TCP connections.
* @param cb the callback object which is invoked to handle
@@ -105,11 +105,11 @@
* to handle per thread
* @param port the port number to bind the server to. <code>Zero</code>
* means choose any free port.
*/
- public HttpServer (HttpCallback cb, int threads, int cperthread, int port)
+ public TestHttpsServer (HttpCallback cb, int threads, int cperthread, int port)
throws IOException {
schan = ServerSocketChannel.open ();
InetSocketAddress addr = new InetSocketAddress (port);
schan.socket().bind (addr);
this.threads = threads;