public class ServletConnection extends Object implements ThreadPool.InterruptableTask
ServletWebServer's
ThreadPool.Task
for handling a single
servlet connection.Constructor and Description |
---|
ServletConnection(javax.servlet.http.HttpServlet pServlet,
Socket pSocket)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
run()
Performs the task.
|
void |
shutdown()
Interrupts the task.
|
public ServletConnection(javax.servlet.http.HttpServlet pServlet, Socket pSocket) throws IOException
pServlet
- The servlet, which ought to handle the request.pSocket
- The socket, to which the client is connected.IOException
public void run() throws Throwable
ThreadPool.Task
run
in interface ThreadPool.Task
Throwable
- The task failed, and the worker thread won't be used again.public void shutdown() throws Throwable
ThreadPool.InterruptableTask
shutdown
in interface ThreadPool.InterruptableTask
Throwable
- Shutting down the task failed.Copyright © 2001–2016 The Apache Software Foundation. All rights reserved.