Class ControllerThreadSocketFactory.SocketTask
- java.lang.Object
-
- org.apache.commons.httpclient.protocol.ControllerThreadSocketFactory.SocketTask
-
- All Implemented Interfaces:
java.lang.Runnable
- Enclosing class:
- ControllerThreadSocketFactory
public abstract static class ControllerThreadSocketFactory.SocketTask extends java.lang.Object implements java.lang.Runnable
Helper class for wrapping socket based tasks.
-
-
Constructor Summary
Constructors Constructor Description SocketTask()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
doit()
Perform the logic.protected java.net.Socket
getSocket()
Return the socket.void
run()
Execute the logic in this object and keep track of any exceptions.protected void
setSocket(java.net.Socket newSocket)
Set the socket.
-
-
-
Method Detail
-
setSocket
protected void setSocket(java.net.Socket newSocket)
Set the socket.- Parameters:
newSocket
- The new socket.
-
getSocket
protected java.net.Socket getSocket()
Return the socket.- Returns:
- Socket The socket.
-
doit
public abstract void doit() throws java.io.IOException
Perform the logic.- Throws:
java.io.IOException
- If an IO problem occurs
-
run
public void run()
Execute the logic in this object and keep track of any exceptions.- Specified by:
run
in interfacejava.lang.Runnable
-
-