com.sun.faban.driver.transport.hc3
Class ProtocolTimedSocketFactory

java.lang.Object
  extended by com.sun.faban.driver.transport.hc3.ProtocolTimedSocketFactory
All Implemented Interfaces:
org.apache.commons.httpclient.protocol.ProtocolSocketFactory

public class ProtocolTimedSocketFactory
extends Object
implements org.apache.commons.httpclient.protocol.ProtocolSocketFactory

The ProtocolTimedSocketFactory is used for the Apache Commons HttpClient 3.1 to let the transport be timed.

Author:
Akara Sucharitakul

Constructor Summary
ProtocolTimedSocketFactory()
           
 
Method Summary
 Socket createSocket(String host, int port)
           
 Socket createSocket(String host, int port, InetAddress localAddress, int localPort)
           
 Socket createSocket(String host, int port, InetAddress localAddress, int localPort, org.apache.commons.httpclient.params.HttpConnectionParams params)
           
 boolean equals(Object obj)
          All instances of ProtocolTimedSocketFactory are the same.
 int hashCode()
          All instances of ProtocolTimedSocketFactory have the same hash code.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProtocolTimedSocketFactory

public ProtocolTimedSocketFactory()
Method Detail

createSocket

public Socket createSocket(String host,
                           int port,
                           InetAddress localAddress,
                           int localPort)
                    throws IOException
Specified by:
createSocket in interface org.apache.commons.httpclient.protocol.ProtocolSocketFactory
Throws:
IOException

createSocket

public Socket createSocket(String host,
                           int port,
                           InetAddress localAddress,
                           int localPort,
                           org.apache.commons.httpclient.params.HttpConnectionParams params)
                    throws IOException
Specified by:
createSocket in interface org.apache.commons.httpclient.protocol.ProtocolSocketFactory
Throws:
IOException

createSocket

public Socket createSocket(String host,
                           int port)
                    throws IOException
Specified by:
createSocket in interface org.apache.commons.httpclient.protocol.ProtocolSocketFactory
Throws:
IOException

equals

public boolean equals(Object obj)
All instances of ProtocolTimedSocketFactory are the same.

Overrides:
equals in class Object
Parameters:
obj - The other object to compare to
Returns:
true if obj is a ProtocolTimedSocketFactory, false otherwise

hashCode

public int hashCode()
All instances of ProtocolTimedSocketFactory have the same hash code.

Overrides:
hashCode in class Object
Returns:
The hash code of the class, thus all instances are the same